I can't listen for the pop-up event because I'm also using the
standard cut, copy, paste shortcut keys (ctrl-x, ctrl-c, ctrl-v),
unless using the shortcut keys activates the menu event too??? I
guess I'll have to try that.
You're right about using "while(1==1)" using a lot of CPU, that's why
I'd make my application multithreaded and use VB's equivalent of
wait() or sleep().
"Dominique Vandensteen" <domi.vds_insert@tralala_tenforce.com> wrote in message news:<uY**************@tk2msftngp13.phx.gbl>...
well i think there must be an event somewhere but I don't know where...
the while(1=1) is a bad idea, will use too much cpu...
something you can also use is listen on the popup event of the menuitem to
dis/enable your menuitem...
hope this helps
dominique
"Stilgar[bbs.isca.uiowa.edu]" <no****@yakhair.com> wrote in message
news:4d*************************@posting.google.co m... Here's my newbie question:
I have several VB forms which are all inherit a standard template form
that I made. In my template form, I added a menu bar with some
generic cut, copy, and paste functionality.
I'd like to have the paste button disabled when the clipboard is
empty, but I'm not sure how I should do this. Ideally, I suppose I'd
like to constantly monitor the clipboard for data, (in a thread?) but
I'm not even sure how I'd monitor the clipboard.
while (1==1)
if clipboard != mt
enable paste
else
disable paste
Or maybe there there's an event that I could monitor?
on Event
if clipboard != mt
enable paste
else
disable paste
What's the best way to tackle this?
TIA