Jump to content

GUICtrlCreateInput


w0uter
 Share

Recommended Posts

If the focus is on the input ctrl at the time enter is pressed it doesnt go to the button.

i now use a lame workaround using hotkeyset('{ENTER}') to send '{TAB}{ENTER}'

(to breakout using $WS_TABSTOP and then send enter)

i was hope'ing that there was a cleaner way.

like removing $ES_MULTILINE or something (but that's forced ...)

Edited by w0uter

My UDF's:;mem stuff_Mem;ftp stuff_FTP ( OLD );inet stuff_INetGetSource ( OLD )_INetGetImage _INetBrowse ( Collection )_EncodeUrl_NetStat_Google;random stuff_iPixelSearch_DiceRoll

Link to comment
Share on other sites

this is my current code with the workaround.

GUICreate("Hex <-> Dec", 120, 20, @DesktopWidth - 122, @DesktopHeight - 52, $WS_POPUPWINDOW)

$h_Input = GUICtrlCreateInput('', 0, 0, 120, 20)
$h_Btn = GUICtrlCreateButton('', 150, 50, default, default, default, $BS_DEFPUSHBUTTON)

GUISetState()

HotKeySet('{ENTER}', 'TE'); comment this out to see my problem

While 1
    Switch GUIGetMsg()
        Case $GUI_EVENT_CLOSE
            Exit
        Case $h_Btn
            $v_I = GUICtrlRead($h_Input)
            GUIDelete()
            ExitLoop
    EndSwitch
WEnd

MsgBox(0, '', '"' & $v_I & '"')
    

Func TE()
    HotKeySet('{ENTER}')
    Send('{TAB}{ENTER}')
EndFunc

My UDF's:;mem stuff_Mem;ftp stuff_FTP ( OLD );inet stuff_INetGetSource ( OLD )_INetGetImage _INetBrowse ( Collection )_EncodeUrl_NetStat_Google;random stuff_iPixelSearch_DiceRoll

Link to comment
Share on other sites

If the focus is on the input ctrl at the time enter is pressed it doesnt go to the button.

i now use a lame workaround using hotkeyset('{ENTER}') to send '{TAB}{ENTER}'

(to breakout using $WS_TABSTOP and then send enter)

i was hope'ing that there was a cleaner way.

like removing $ES_MULTILINE or something (but that's forced ...)

<{POST_SNAPBACK}>

you can unset $ES_MULTILINE after the control has been created....
[u]Do more with pre-existing apps![/u]ANYGUIv2.8
Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...