#include <GUIConstantsEx.au3> #include <GUIEdit.au3> ; Opt("GUIOnEventMode", 1) $Form = GUICreate("Только как пример", 524, 204, 203, 181) GUISetOnEvent($GUI_EVENT_CLOSE, "Close") $Edit = GUICtrlCreateEdit("", 8, 8, 249, 153) GUICtrlSetColor(-1, 0xff0000) GUICtrlSetFont(-1, 10, 800) $Button1 = GUICtrlCreateButton("Добавить текст в поле Edit", 8, 168, 249, 25, 0) GUICtrlSetOnEvent(-1, "AddEdit") $List = GUICtrlCreateList("", 272, 8, 241, 149) GUICtrlSetColor(-1, 0xff0000) GUICtrlSetFont(-1, 10, 800) $Button2 = GUICtrlCreateButton("Добавить текст в поле List", 272, 168, 241, 25, 0) GUICtrlSetOnEvent(-1, "AddList") GUISetState(@SW_SHOW) While 1 Sleep(30) WEnd Func Close() GUIDelete($Form) Exit EndFunc Func AddEdit() _GUICtrlEdit_AppendText($Edit, "Этот текс должен быть красным" & @CRLF) _GUICtrlEdit_AppendText($Edit, "Этот текс должен быть черным" & @CRLF) EndFunc Func AddList() GUICtrlSetData($List, "Этот текс должен быть красным" & @CRLF, "-") GUICtrlSetData($List, "Этот текс должен быть черным" & @CRLF, "-") EndFunc |