imani Posted October 9, 2007 Share Posted October 9, 2007 (edited) Look in the following code. When I press the button 1 then I want to display the following output in the GUIctrlCreateedit window Output Line 1 Line 2 Line 3 I do want to add some functions before and after the GUICtrlSetData commands (Can not use @CRLF) expandcollapse popup#include <GUIConstants.au3> #NoTrayIcon Global $mainwin= GUICreate("Utility 3.1.1", 270,250) GUISwitch($mainwin) $Button_1 = GuiCtrlCreateButton("Button1", 40, 20, 170, 30) GUICtrlSetState($Button_1,$GUI_FOCUS) $Button_2 = GuiCtrlCreateButton("Button2", 40, 60, 170, 30) $Button_3 = GuiCtrlCreateButton("Button3", 40, 100, 170, 30) $exit = GuiCtrlCreateMenu ("File") $exititem = GUICtrlCreateMenuitem ("Exit",$exit) $helpmenu = GuiCtrlCreateMenu ("Help") $readmeitem = GuiCtrlCreateMenuitem ("Readme",$helpmenu) $aboutitem = GuiCtrlCreateMenuitem ("About",$helpmenu) $edit = GUICtrlCreateEdit("",0,150,270,80,BitOR($ES_READONLY,$ES_MULTILINE),$WS_EX_STATICEDGE) GUISetState () While 1 $msg = GUIGetMsg() Select Case $msg = $GUI_EVENT_CLOSE ExitLoop Case $msg = $Button_1 GUICtrlSetData($edit,"Line 1") ;I want to put separate function here GUICtrlSetData($edit,"Line 2") ;I want to put separate function here GUICtrlSetData($edit,"Line 3") Case $msg = $Button_2 Case $msg = $Button_3 Case $msg = $exititem ExitLoop Case $msg = $aboutitem Case $msg = $readmeitem EndSelect Wend Edited October 10, 2007 by imani Link to comment Share on other sites More sharing options...
smashly Posted October 9, 2007 Share Posted October 9, 2007 Hi, Replace GUICtrlSetData($edit,"Line 1") GUICtrlSetData($edit,"Line 2") GUICtrlSetData($edit,"Line 3")oÝ÷ Ùh«¢+ÙU% ÑɱMÑÑ ÀÌØí¥Ð°ÅÕ½Ðí1¥¹ÄÅÕ½ÐìµÀì I1µÀìÅÕ½Ðí1¥¹ÈÅÕ½ÐìµÀì I1µÀìÅÕ½Ðí1¥¹ÌÅÕ½Ðì¤Cheers Link to comment Share on other sites More sharing options...
imani Posted October 10, 2007 Author Share Posted October 10, 2007 Please Help Link to comment Share on other sites More sharing options...
smashly Posted October 10, 2007 Share Posted October 10, 2007 Hi again, GUICtrlSetData($edit,"Line 1") ;I want to put separate function here GUICtrlSetData($edit, GUICtrlRead($edit) & @CRLF & "Line 2") ;I want to put separate function here GUICtrlSetData($edit, GUICtrlRead($edit) & @CRLF & "Line 3") Cheers Link to comment Share on other sites More sharing options...
imani Posted October 11, 2007 Author Share Posted October 11, 2007 Hi again, GUICtrlSetData($edit,"Line 1") ;I want to put separate function here GUICtrlSetData($edit, GUICtrlRead($edit) & @CRLF & "Line 2") ;I want to put separate function here GUICtrlSetData($edit, GUICtrlRead($edit) & @CRLF & "Line 3") CheersA simple method to do so GUICtrlSetData($edit,"Line 1","append") GUICtrlSetData($edit,@CRLF & "Line 2","append") GUICtrlSetData($edit,@CRLF & "Line 3","append") Link to comment Share on other sites More sharing options...
imani Posted October 11, 2007 Author Share Posted October 11, 2007 Hi again, GUICtrlSetData($edit,"Line 1") ;I want to put separate function here GUICtrlSetData($edit, GUICtrlRead($edit) & @CRLF & "Line 2") ;I want to put separate function here GUICtrlSetData($edit, GUICtrlRead($edit) & @CRLF & "Line 3")oÝ÷ Ø(^z»?ªê-x"^ëa¡Ûhv(jëh×6 GUICtrlSetData($edit,"Line 1","append") GUICtrlSetData($edit,@CRLF & "Line 2","append") GUICtrlSetData($edit,@CRLF & "Line 3","append") Link to comment Share on other sites More sharing options...
GaryFrost Posted October 11, 2007 Share Posted October 11, 2007 _GUICtrlEdit_AppendText SciTE for AutoItDirections for Submitting Standard UDFs Don't argue with an idiot; people watching may not be able to tell the difference. 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