Jump to content

Recommended Posts

  • Developers
Posted

hello

how can i set a hotkey that return the script to the beggining? that simple

plz help! i can´t find a solution =S

You can set a Global value and test for that to perform a ContinueLoop inside a While...Wend

HotKeySet("{F1}", "PlayBack")

Func Play()
 ;Put code here
EndFunc

That will let you use the kot key (which in this case is F1).

Yep... that will bring you right to the End ..

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.
  :)

Posted

You can set a Global value and test for that to perform a ContinueLoop inside a While...Wend

Yep... that will bring you right to the End ..

Well Anything did ask how to set a Hot Key...

[font="Comic Sans MS"]BA-LA[/font]http://ba-la.110mb.comJoin my community, CLICK HEREAlternative links to my site:http://www.ba-la.tkhttp://www.ba-la.co.nrContact me if you would like to help with some of my projects: joeythepirate@gmail.com
Posted

hello

how can i set a hotkey that return the script to the beggining? that simple

plz help! i can´t find a solution =S

PCP

If you would, it would be much easier to loop your script.

Posted

well, i´m sorry to say this but

no one has help me

xD! what i want to say is, for example

While 1
                $nMsg = GUIGetMsg()
    Switch $nMsg
        Case $Btn2
            Exit
            
        Case $b1 
            $nb1 = Pick($b1)
        Case $b2
            $nb2 = Pick($b2)
        Case $b3
            $nb3 = Pick($b3)
        Case $b4                                        ;======================================
            $nb4 = Pick($b4)             ; when the program reaches this line and i prees a hotkey
                                                              ; the program returns to the beggining
        Case $Btn1                                   ;======================================
            WinClose
            If $nb1 = True Then
                AbrirCarp()
            EndIf
            
            If $nb2 = True Then
                AbrirThis()
            EndIf
            
            If $nb3 = True Then
                CorrerProg()
            EndIf
            
            If $nb4 = True Then
                EscRep()
            EndIf
                
    EndSwitch
WEnd
Posted

...no one has help me...

There is a difference between saying that you do not understand the help that Jdeb has given you and saying that no one has helped you..........

[size="1"][font="Arial"].[u].[/u][/font][/size]

Posted (edited)

I cannot test this and I'm not sure of the ContinueLoop level... or maybe you should read about ContinueCase

HotKeySet("{F2}", "_StartOver")
Global $trigger = 0

While 1 ;starts over here
    $nMsg = GUIGetMsg()
    Switch $nMsg
        Case $Btn2
            Exit

        Case $b1
            $nb1 = Pick ($b1)
        Case $b2
            $nb2 = Pick ($b2)
        Case $b3
            $nb3 = Pick ($b3)
        Case $b4
            $nb4 = Pick ($b4)

            If $trigger = 1 Then
                $trigger = 0
                ContinueLoop ;starts over
                ;or see ContinueCase
            EndIf

        Case $Btn1
            WinClose
            If $nb1 = True Then
                AbrirCarp ()
            EndIf

            If $nb2 = True Then
                AbrirThis ()
            EndIf

            If $nb3 = True Then
                CorrerProg ()
            EndIf

            If $nb4 = True Then
                EscRep ()
            EndIf

    EndSwitch
WEnd

Func _StartOver()
    $trigger = 1
EndFunc   ;==>_StartOver

Edited by herewasplato

[size="1"][font="Arial"].[u].[/u][/font][/size]

Posted

I had a similar problem a while back, and I still haven't solved it. :P

Why did you have to murder the GoTo command, AutoItv3? Why, why, why? :D

I agree. although it's true that there is a different way to do everything without goto, it is still useful in cases such as this

The cake is a lie.www.theguy0000.com is currentlyUP images.theguy0000.com is currentlyUP all other *.theguy0000.com sites are DOWN

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
  • Recently Browsing   0 members

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