Jump to content

reminder with GUI


Recommended Posts

  • Moderators

sleep($data*1000)
TrayTip("", "cas " & $data, 5)
        GUISetState(@SW_SHOW)

    Case $msg = $cancel3
         ExitLoop

GUICtrlSetState( -1, $GUI_DEFBUTTON)

Try setting : GUICtrlSetState( -1, $GUI_DEFBUTTON)

To: GUICtrlSetState( $ok2, $GUI_DEFBUTTON)

Common sense plays a role in the basics of understanding AutoIt... If you're lacking in that, do us all a favor, and step away from the computer.

Link to comment
Share on other sites

Paste over your whole code with this:

#include <GUIConstants.au3>
AutoItSetOption ( "SendKeyDelay", 300 )

;If Not IsDeclared('WS_CLIPSIBLINGS') Then Global $WS_CLIPSIBLINGS = 0x04000000
GuiCreate("MyGUI", 274, 120,(@DesktopWidth-274)/2, (@DesktopHeight-120)/2 , $WS_OVERLAPPEDWINDOW + $WS_VISIBLE + $WS_CLIPSIBLINGS)

$text = GuiCtrlCreateEdit("", 10, 10, 250, 70)
$Combo_4 = GuiCtrlCreateCombo("5", 10, 80, 110)
$ok2 = GuiCtrlCreateButton("OK", 130, 80, 50, 20,$BS_defpushbutton)
$cancel3 = GuiCtrlCreateButton("Cancel", 190, 80, 50, 20)
GuiCtrlSetData($combo_4, "1|5|10|30|60|90|120", "1")

while 1
    

GuiSetState()

    $msg = GuiGetMsg()
    Select
    Case $msg = $GUI_EVENT_CLOSE
         ExitLoop
        
    Case $msg = $ok2
      $data = GUICtrlRead($Combo_4)
        GUISetState(@SW_HIDE)
      sleep($data*1000)
        GUISetState(@SW_SHOW)
    Case $msg = $cancel3
         ExitLoop
    EndSelect

WEnd

Exit
Edited by SupraNatural

Visit http://www.blizzedout.com/forums/register....referrerid=8306 for the top blizzard hacks. WoW, TfT, D2/LOD, CS. You name it we got it!

Link to comment
Share on other sites

YES YES YES

THATS IT

THANKE YOU

YUE HAVE a big patience with me :whistle:)))))

I have next task but i dont want to misuse your great knowledges

fyi

i want to make little bubble in trey and in buble will be countdown to show this remind text :dance:)))

is it too hard? :dance:

Link to comment
Share on other sites

Paste over your whole code with this:

#include <GUIConstants.au3>
AutoItSetOption ( "SendKeyDelay", 300 )

;If Not IsDeclared('WS_CLIPSIBLINGS') Then Global $WS_CLIPSIBLINGS = 0x04000000
GuiCreate("MyGUI", 274, 120,(@DesktopWidth-274)/2, (@DesktopHeight-120)/2 , $WS_OVERLAPPEDWINDOW + $WS_VISIBLE + $WS_CLIPSIBLINGS)

$text = GuiCtrlCreateEdit("", 10, 10, 250, 70)
$Combo_4 = GuiCtrlCreateCombo("5", 10, 80, 110)
$ok2 = GuiCtrlCreateButton("OK", 130, 80, 50, 20,$BS_defpushbutton)
$cancel3 = GuiCtrlCreateButton("Cancel", 190, 80, 50, 20)
GuiCtrlSetData($combo_4, "1|5|10|30|60|90|120", "1")

while 1
    

GuiSetState()

    $msg = GuiGetMsg()
    Select
    Case $msg = $GUI_EVENT_CLOSE
         ExitLoop
        
    Case $msg = $ok2
      $data = GUICtrlRead($Combo_4)
        GUISetState(@SW_HIDE)
      sleep($data*1000)
        GUISetState(@SW_SHOW)
    Case $msg = $cancel3
         ExitLoop
    EndSelect

WEnd

Exit

<{POST_SNAPBACK}>

he has been trying to say when he

1

types in a message

2

tabs to the drop-down list and the default number 1 is there

3

press enter

and it will work....

what are you thinking you wrote a code for this before.... and now you took that part out... why???

8)

NEWHeader1.png

Link to comment
Share on other sites

this will do the trick

#include <GUIConstants.au3>
AutoItSetOption ( "SendKeyDelay", 300 )

;If Not IsDeclared('WS_CLIPSIBLINGS') Then Global $WS_CLIPSIBLINGS = 0x04000000
GuiCreate("MyGUI", 274, 120,(@DesktopWidth-274)/2, (@DesktopHeight-120)/2 , $WS_OVERLAPPEDWINDOW + $WS_VISIBLE + $WS_CLIPSIBLINGS)

$text = GuiCtrlCreateEdit("", 10, 10, 250, 70)
$Combo_4 = GuiCtrlCreateCombo("5", 10, 80, 110)
$ok2 = GuiCtrlCreateButton("OK", 130, 80, 50, 20)
GUICtrlSetState( -1, $GUI_DEFBUTTON)
$cancel3 = GuiCtrlCreateButton("Cancel", 190, 80, 50, 20)
GuiCtrlSetData($combo_4, "1|5|10|30|60|90|120", "1")

while 1
    

GuiSetState()

    $msg = GuiGetMsg()
    Select
    Case $msg = $GUI_EVENT_CLOSE
         ExitLoop
        
    Case $msg = $ok2
      $data = GUICtrlRead($Combo_4)
        GUISetState(@SW_HIDE)
        for $x = $data to 1 Step -1
        TrayTip("Time delay", "The delay will return in " & $x & " seconds  ","1",1) 
        sleep(1000)
        TrayTip("clears any tray tip","",0)
        Next
        GUISetState(@SW_SHOW)
   ;Case $msg = $Combo_4
   ;  $data = GUICtrlRead($Combo_4)
   ;    GUISetState(@SW_HIDE)
   ;  sleep($data*1000)
   ;    GUISetState(@SW_SHOW)
    Case $msg = $cancel3
         ExitLoop
    EndSelect

WEnd

Exit

8)

NEWHeader1.png

Link to comment
Share on other sites

like this

#include <GUIConstants.au3>
AutoItSetOption ( "SendKeyDelay", 300 )

;If Not IsDeclared('WS_CLIPSIBLINGS') Then Global $WS_CLIPSIBLINGS = 0x04000000
GuiCreate("MyGUI", 274, 120,(@DesktopWidth-274)/2, (@DesktopHeight-120)/2 , $WS_OVERLAPPEDWINDOW + $WS_VISIBLE + $WS_CLIPSIBLINGS)

$text = GuiCtrlCreateEdit("", 10, 10, 250, 70)
$Combo_4 = GuiCtrlCreateCombo("5", 10, 80, 110)
$ok2 = GuiCtrlCreateButton("OK", 130, 80, 50, 20)
GUICtrlSetState( -1, $GUI_DEFBUTTON)
$cancel3 = GuiCtrlCreateButton("Cancel", 190, 80, 50, 20)
GuiCtrlSetData($combo_4, "1|5|10|30|60|90|120", "1")

while 1
    

GuiSetState()

    $msg = GuiGetMsg()
    Select
    Case $msg = $GUI_EVENT_CLOSE
         ExitLoop
        
    Case $msg = $ok2
      $data = GUICtrlRead($Combo_4)
        GUISetState(@SW_HIDE)
        for $x = $data to 1 Step -1
        TrayTip("Time delay", "The delay will return in " & $x & " seconds  ","1",1)
        $pos = MouseGetPos()
        If $pos[0] > @DesktopWidth - 260 And $pos[1] > @DesktopHeight - 90 Then
            TrayTip("clears any tray tip","",0)
            ExitLoop 
        EndIf
        sleep(1000)
        TrayTip("clears any tray tip","",0)
        Next
        GUISetState(@SW_SHOW)
   ;Case $msg = $Combo_4
   ;  $data = GUICtrlRead($Combo_4)
   ;    GUISetState(@SW_HIDE)
   ;  sleep($data*1000)
   ;    GUISetState(@SW_SHOW)
    Case $msg = $cancel3
         ExitLoop
    EndSelect

WEnd

Exit

Just place the mouse over the tray message box...

and no, i am not the sharpest here, i am just a hobbiest... but thanks

8)

NEWHeader1.png

Link to comment
Share on other sites

  • 3 weeks later...

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 account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...