Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
Send Keys to Open Userform
Is it possible to SendKeys to an Open/ Running Userform from another
macro once that Userform is waiting for a user action, say using accelerator keys. It seems I can only do this from the keyboard once the Userform is open. Thanks Gang! My turn to try answering some questions too. Best, J |
#2
Posted to microsoft.public.excel.programming
|
|||
|
|||
Send Keys to Open Userform
'xxxxxxxxxxxxxxxxxxxxxx
'in the standard module Sub test() UserForm1.Show 0 End Sub Sub YourMacro() UserForm2.Show 0 End Sub 'xxxxxxxxxxxxxxxxxxxxxxx 'in the userform1 module Private Sub UserForm_KeyDown(ByVal KeyCode As MSForms.ReturnInteger, ByVal Shift As Integer) 'Ctrl+k Debug.Print KeyCode If KeyCode = 17 And Shift = 2 Then YourMacro End If End Sub regards r -- http://excelvba.altervista.org/blog/...ternative.html "mrkt_rwnd" wrote: Is it possible to SendKeys to an Open/ Running Userform from another macro once that Userform is waiting for a user action, say using accelerator keys. It seems I can only do this from the keyboard once the Userform is open. Thanks Gang! My turn to try answering some questions too. Best, J |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
need help using send keys | Excel Programming | |||
SEND KEYS?????? Please.... help... | Excel Programming | |||
Send Keys | Excel Programming | |||
Send Keys | Excel Programming | |||
Send Keys | Excel Programming |