|
-
February 23rd, 2000, 08:16 AM
#1
Popupmenu in textboxes
Hello everybody,
I need your help. When clicking with the right mousebutton on a textbox creates a popupmenu with items like Cut, Copy, Paste an so on. Is there anything I can do to disable this popupmenu. I thin I have to set an exteded style for the textbox with the API function SetWindowLong, but I don't know how this function has to be called to do the right thing. I hope somebody could help me with this.
Best regards
Michael Hartmann
-
February 23rd, 2000, 08:40 AM
#2
Re: Popupmenu in textboxes
The proper way would be to subclass it.
I'm not sure of how to remove the menu completely but have a look at Randy Birch's site http://www.mvps.org/vbnet
This may give you some tips.
If all you want to do is use your own popup menu that do the following.
private Sub Text1_MouseDown(Button as Integer, Shift as Integer, X as Single, Y as Single)
Text1.Enabled = false
PopupMenu Mymenu
Text1.Enabled = true
End Sub
This will replace the default menu with your own popup menu.
Hope this helps.
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
|