ezzetabi Posted September 3, 2004 Share Posted September 3, 2004 As you all already probably know I am creating a Run dialogue:Run!So far so good, the problem is Larry adviced me to change the Control where the user put inputs from a "input" to a "combo" control and to manage history.Making the new GUI has been quite easy and also managing the history as a pipe delimeted variable, but I have some problems. I'd like to know if it is a problem of my script or of the combo controls...1- I can't set the text inside the combo as easy as inside the input, in the input it is enough using a GUIWrite($CTR_INPUT,'','Text'), but I can't do the same in the combo.2- I can't find the way to avoid that you lose the text you wrote if you have the combo box open while you type and you press Enter. 3- there is a way to enable autocomplete while the user type something that is already in the combo box items?Thanks anyone! If it can't be solved, I'll return to my good old "input" and I'll manage history via hotkey, like the good old dos days... Scrap of code of GUI creation... if it is useful.$COMMONSTYLE = $WS_MINIMIZEBOX + $WS_GROUP + $WS_POPUP If IniRead('"' & @ScriptDir & '\settings.ini"', 'main', 'alwaysontop', 0) = 1 Then $COMMONSTYLEEX = $WS_EX_TOPMOST + $WS_EX_ACCEPTFILES Else $COMMONSTYLEEX = $WS_EX_ACCEPTFILES EndIf GUICreate( "-+R-u-n+-!", 270, 22, @DesktopWidth / 2 - 20, 0, $COMMONSTYLE, $COMMONSTYLEEX) $EDITSTYLE = $CBS_DROPDOWN + $CBS_AUTOHSCROLL + $WS_VSCROLL + $CBS_SORT $CTR_INPUT = GUISetControl("combo", '', 41, 1, 200, 200, $EDITSTYLE) GUISetControlEx($CTR_INPUT, $GUI_FOCUS + $GUI_ACCEPTFILES) GUISetControlData($CTR_INPUT, $HISTORY) $BUTTONSTYLE = $BS_CENTER + $BS_FLAT $CTR_OK = GUISetControl("button", '&Run!', 241, 1, 28, 19, $BUTTONSTYLE) GUISetControlEx($CTR_OK, $GUI_DEFBUTTON) $CTR_OPEN = GUISetControl("button", '&Open...', 1, 1, 40, 19, $BUTTONSTYLE) Link to comment Share on other sites More sharing options...
ezzetabi Posted September 7, 2004 Author Share Posted September 7, 2004 How can I $GUI_ACCEPTFILES to the input part of the combo box? Link to comment Share on other sites More sharing options...
Recommended Posts
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 accountSign in
Already have an account? Sign in here.
Sign In Now