Didonet 0 Posted September 9, 2007 Can u give some idea to change the value of this thing? i use this code for program status: $statuslabel = GUICtrlCreateLabel ("Status: Offline",0,165,300,16,BitOr($SS_SIMPLE,$SS_SUNKEN)) but when i write: $statuslabel = GUICtrlCreateLabel ("Status: Offline",0,165,300,16,BitOr($SS_SIMPLE,$SS_SUNKEN)) $statuslabel = GUICtrlCreateLabel ("Status: Online",0,165,300,16,BitOr($SS_SIMPLE,$SS_SUNKEN)) The last label goes of the top on the other one... Can i create a dynamic label? Share this post Link to post Share on other sites
Jos 2,281 Posted September 9, 2007 GuiCtrlSetData($Statuslabel,"NewText") SciTE4AutoIt3 Full installer Download page - Beta files Read before posting How to post scriptsource Forum etiquette Forum Rules Live for the present, Dream of the future, Learn from the past. Share this post Link to post Share on other sites
Didonet 0 Posted September 9, 2007 (edited) Can i refresh it like that? Func status_check() Global $statuslabel While 1 Sleep(120000) ; 2 minutes If Ping("site.com", 250) Then GuiCtrlSetData($statuslabel,"Статус: свързан") Else GuiCtrlSetData($statuslabel,"Статус: изключен") EndIf WEnd EndFunc when i enter in the gui check_status() the gui opens, but it cannot do anything. It refreshes the status. I want to refresh the status and i want the gui to works at same time... note: if i set the check_status() before the gui its the same thing... Edited September 9, 2007 by Didonet Share this post Link to post Share on other sites
Jos 2,281 Posted September 9, 2007 Can i refresh it like that?Func status_check() Global $statuslabel While 1 Sleep(120000) ; 2 minutes If Ping("site.com", 250) Then GuiCtrlSetData($statuslabel,"Статус: свързан") Else GuiCtrlSetData($statuslabel,"Статус: изключен") EndIf WEndEndFuncwhen i enter in the gui check_status() the gui opens, but it cannot do anything. It refreshes the status. I want to refresh the status and i want the gui to works at same time...note: if i set the check_status() before the gui its the same thing...That is because you have a while-wend in there that is never left....You need to return to the loop where you read the GUI messages . SciTE4AutoIt3 Full installer Download page - Beta files Read before posting How to post scriptsource Forum etiquette Forum Rules Live for the present, Dream of the future, Learn from the past. Share this post Link to post Share on other sites
Didonet 0 Posted September 9, 2007 You need to return to the loop where you read the GUI messages .What do u mean with that? I show the gui messages when i create the gui... Share this post Link to post Share on other sites