On Apr 16, 10:52 am, "Jan Hyde (VB MVP)"
<StellaDrin...@REMOVE.ME.uboot.com> wrote:
> "Michael" <michae...@gmail.com>'s wild thoughts were
> released on 13 Apr 2007 19:27:53 -0700 bearing the following
> fruit:
>
> >Hi,
> >There is a menuitem in my windows application called Fill Data.
> >If user click this menu, one of the textbox will be filled in some
> >value.
> >Now I hope it work like this,
> >When user clicks this menu, at the same time, he presses Ctrl key, all
> >the textboxes will be filled in with some values.
> >How can I do that? Seems there is no keypress event for a menuitem?
> >Thanks!
>
> No but you can test the keyboard state when the item is
> clicked. Something like this for example
>
> If Control.ModifierKeys = Keys.Control Then
> Me.Text = "CONTROL+CLICK"
> Else
> Me.Text = "CLICK"
> End If
Cool!!
It works!
Thank you very much!
|