|
-
Apr 3rd, 2002, 04:38 PM
#1
Thread Starter
Addicted Member
Functions like Cut, copy and paste..How?
How can i use function like that in a prog that uses many many textboxes? do i have to programm them for each textbox indevidually? thnx
-
Apr 3rd, 2002, 07:31 PM
#2
Frenzied Member
You dont have to, if you have text boxes on a form, you'll automatically get the context menu with cut, paste, copy etc. when you right click.
Dont gain the world and lose your soul
-
Apr 4th, 2002, 08:52 AM
#3
Thread Starter
Addicted Member
but i want them in the menu, just like any other prog...
-
Apr 4th, 2002, 09:01 AM
#4
Frenzied Member
The right-click Context menu is automaticly added, but if you mean just the functions to copy & paste? Then you should use the Clipboard object...
I wrote two small functions for you to show how it works:
VB Code:
Private Function GetClipBoardText() As String
If Clipboard.GetDataObject.GetDataPresent("Text") Then
Return Clipboard.GetDataObject.GetData("Text")
End If
End Function
Private Sub SetClipBoardText(ByVal sString As String)
Clipboard.SetDataObject(sString)
End Sub
Jop - validweb.nl
Alcohol doesn't solve any problems, but then again, neither does milk.
-
Apr 4th, 2002, 10:30 AM
#5
Thread Starter
Addicted Member
that's what i mean! thanx alot!
-
Apr 4th, 2002, 10:56 AM
#6
Thread Starter
Addicted Member
hmmm since i have lots of textboxes in my app is there someway i can make a sub to all of them? like the copy function...can i make it for for all textboxes at once?
-
Apr 4th, 2002, 11:38 AM
#7
Frenzied Member
I don't really see what you mean...
you mean like if you click the paste button that it will paste in all textboxes or what?
Jop - validweb.nl
Alcohol doesn't solve any problems, but then again, neither does milk.
-
Apr 4th, 2002, 01:58 PM
#8
Thread Starter
Addicted Member
I found it out alrteady . it's like textbox1.copy , .cut , that's what i was looking for, thnx anyway
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|