Sign in to follow this  
Followers 0
GoA_TrancE

How To End Script

6 posts in this topic

any ideas?

Share this post


Link to post
Share on other sites



From HotKeySet help page in the help file:

HotKeySet("{ESC}", "Terminate")

;;;; Body of program would go here;;;;
While 1
    Sleep(100)
WEnd
;;;;;;;;

Func Terminate()
    Exit 0
EndFunc

Share this post


Link to post
Share on other sites

10x You :think:

Share this post


Link to post
Share on other sites

what do u mean whit this?

";;;; Body of program would go here;;;;"

This is my code:

HotKeySet("{END}", "Terminate")
While 1
    Sleep(400)
WEnd
Func Terminate()
    Exit 0
EndFunc
its correct?

Share this post


Link to post
Share on other sites

#5 ·  Posted (edited)

He's saying if there is any other part of your program, but your's looks fine (if all you are going to do is sleep and exit :think:

Edit:

Except the "Is this correct?" should be outside the code (I'm sure it is, just making sure :( )

Edited by SmOke_N

[center]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.[/center]

Share this post


Link to post
Share on other sites

Your code does nothing but wait to end. Unless you just want to slow your pc down, you may want to add code to do something else. That code would go between the 'HotKeySet' and 'Func Terminate'.


“Give a man a script; you have helped him for today. Teach a man to script; and you will not have to hear him whine for help.”AutoIt4UE - Custom AutoIt toolbar and wordfile for UltraEdit/UEStudio users.AutoIt Graphical Debugger - A graphical debugger for AutoIt.SimMetrics COM Wrapper - Calculate string similarity.

Share this post


Link to post
Share on other sites

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
Sign in to follow this  
Followers 0