win32lib pronlem
- Posted by ChrisB (moderator) 2 weeks ago
- 304 views
Hi
Win32lib
Simple dialogue with editText entry, an ok and a cancel button.
How do i simulate a click of the ok button when I hit enter when entering text?
procedure EditText19_onKeyUp (integer self, integer event, sequence params)--params is ( int scanCode, int shift ) if params[1] = VK_RETURN then puts(1, "PushButton20 clicked \n") -- it does trigger when Enter is pressed setFocus(PushButton20) -- makes no difference sendMessage(PushButton20, w32HClick, 0, 0) end if end procedure setHandler( EditText19, w32HKeyUp, routine_id("EditText19_onKeyUp"))
TIA Chris