bobheart Posted August 12, 2004 Share Posted August 12, 2004 I'm trying to show the time in the gui but from the help file nothing showing how it is done so not sure how to do it . I have this but it just just the @min etc .How do you show the time or and date in the gui ?#cs - ### Generated by AutoBuilder 0.4 -- do not modify ###394 2710 0 0 0 0 0 0 0 0 1 0 0 0 0 0 0 label $label_1 Label 1 30 30 170 50 0 0 #ce - ### End of Dump ###;Script generated by AutoBuilder 0.4Opt("GUICoordMode", 1)Opt("GUINotifyMode", 1)GuiCreate("MyGUI", 392,266,(@DesktopWidth-392)/2, (@DesktopHeight-266)/2 , 0x04CF0000)$label_1 = GUISetControl("label", ("@HOUR ,@MIN,@SEC "), 30, 30, 170, 50)GuiShow()While 1 sleep(100) $msg = GuiMsg(0) Select Case $msg = -3 Exit Case $msg = 0 ;;; Case $msg = $label_1 ;;; EndSelectWEndExit Link to comment Share on other sites More sharing options...
bobheart Posted August 12, 2004 Author Share Posted August 12, 2004 Anyone ? Link to comment Share on other sites More sharing options...
lordflyingpoo Posted August 12, 2004 Share Posted August 12, 2004 are you looking for maybe this here or am i way off? Opt ("GUICoordMode", 1) Opt ("GUINotifyMode", 1) GUICreate("MyGUI", 392, 266, (@DesktopWidth - 392) / 2, (@DesktopHeight - 266) / 2, 0x04CF0000) $LABEL_1 = GUISetControl("label", @HOUR & ":" & @MIN & ":" & @SEC, 30, 30, 170, 50) GUIShow() While 1 Sleep(100) $MSG = GUIMsg(0) Select Case $MSG = -3 Exit Case $MSG = 0 ;;; Case $MSG = $LABEL_1 ;;; EndSelect Wend Exit hope it helps. our father, who art in heaven, and to the republic for which it stands, thy kingdom come, one nation, indivisible, as it is in heaven, give us this day as we forgive those who so proudly we hail, and crown thy good into temptation, but deliver us from the twilight. amen. Link to comment Share on other sites More sharing options...
bobheart Posted August 12, 2004 Author Share Posted August 12, 2004 Yes thats what I was looking for . I guess the sec's don't change in the gui unless you refresh the gui . Link to comment Share on other sites More sharing options...
SlimShady Posted August 12, 2004 Share Posted August 12, 2004 (edited) Yes thats what I was looking for . I guess the sec's don't change in the gui unless you refresh the gui . <{POST_SNAPBACK}>Here's how you want it: Opt ("GUICoordMode", 1) Opt ("GUINotifyMode", 1) GUICreate("MyGUI", 392, 266, (@DesktopWidth - 392) / 2, (@DesktopHeight - 266) / 2, 0x04CF0000) $LABEL_1 = GUISetControl("label", "", 30, 30, 170, 50) GUIShow() $x = 1 While 1 $MSG = GUIMsg(0) Select Case $MSG = -3 Exit Case $MSG = 0 ;;; Case $MSG = $LABEL_1 ;;; EndSelect If $x = 9 Then $x = 0 GUIWrite($LABEL_1, 0, @HOUR & ":" & @MIN & ":" & @SEC) EndIf $x = $x + 1 Sleep(100) Wend Exit Edited August 12, 2004 by SlimShady Link to comment Share on other sites More sharing options...
bobheart Posted August 12, 2004 Author Share Posted August 12, 2004 Thanks Slim that works nice .. Link to comment Share on other sites More sharing options...
SlimShady Posted August 12, 2004 Share Posted August 12, 2004 I noticed that sometimes it skips a second. I fixed it. 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