Saagar Posted June 23, 2010 Share Posted June 23, 2010 I need code to set some text in an edit box control _GUICtrlEdit_SetText($hedit, test) Trying with the above function. please advice how to make a stmt. Link to comment Share on other sites More sharing options...
sahsanu Posted June 23, 2010 Share Posted June 23, 2010 I need code to set some text in an edit box control_GUICtrlEdit_SetText($hedit, test)Hello,You should take a look to GUICtrlSetDataRegards,sahsanu Link to comment Share on other sites More sharing options...
Andreik Posted June 23, 2010 Share Posted June 23, 2010 You need to use GUIEdit.au3 and the text to be between ' ' Search for _GUICtrlEdit_SetText() example in help file. When the words fail... music speaks. Link to comment Share on other sites More sharing options...
UEZ Posted June 23, 2010 Share Posted June 23, 2010 (edited) Here an example: expandcollapse popup#include <Constants.au3> #include <GUIConstantsEx.au3> #include <WindowsConstants.au3> #include <EditConstants.au3> Global $iMemo $hGUI = GUICreate("Test", 640, 480) $iMemo = GUICtrlCreateEdit("", 0, 0, 640, 480, $ES_AUTOVSCROLL + $WS_VSCROLL + $ES_READONLY) GUICtrlSetLimit(-1, 0x7FFFFFFF) GUICtrlSetFont($iMemo, 9, 400, 0, "Courier New") GUISetState() $prg = "dir " $parameter = @SystemDir & " /s" $run = Run(@ComSpec & " /c " & $prg & $parameter, @ScriptDir, @SW_HIDE, $STDOUT_CHILD) While 1 $line = StdoutRead($run) If @error Then ExitLoop MemoWrite($line) Wend While 1 $Msg = GUIGetMsg() If $Msg = $GUI_EVENT_CLOSE Then ExitLoop WEnd $save = MsgBox(4 + 32 + 256, "Save", "Save log?", 10) If $save = 6 Then $file = FileSaveDialog("Save Log", @ScriptDir, "Log (*.log;*.txt)", 18) If Not @error Then $log = GUICtrlRead($iMemo) FileWrite($file, $log) FileClose($file) EndIf EndIf Exit ; Write a line to the memo control Func MemoWrite($sMessage) ;~ GUICtrlSetData($iMemo, $sMessage & @CRLF, 1) GUICtrlSetData($iMemo, $sMessage, 1) EndFunc ;==>MemoWrite BR, UEZ Edited June 23, 2010 by UEZ Please don't send me any personal message and ask for support! I will not reply! Selection of finest graphical examples at Codepen.io The own fart smells best! ✌Her 'sikim hıyar' diyene bir avuç tuz alıp koşma!¯\_(ツ)_/¯ ٩(●̮̮̃•̃)۶ ٩(-̮̮̃-̃)۶ૐ 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