Jump to content
Sign in to follow this  
Whips87

HELP ME PLEASE

Recommended Posts

Whips87

Hello! im trying to figure how can i make a script that will not '' Loop ''

so acutaly when i press 1 i want it send 5 time 1 1 1 1 1

so acutaly when i press 2 i want it send 5 time 2 2 2 2 2

so acutaly when i press 3 i want it send 5 time 3 3 3 3 3

im stuck on .. the beggin so

just figured how to do a HotKeySet("{1}", "Key1")

atm my script look like that but .. nothing work lol

HotKeySet("{1}", "Key1")
HotKeySet("{2}", "Key2")
HotKeySet("{3}", "Key3")
;---------------------------------------
While 1
 Sleep(1500)
 Key1()
 Key2()
 Key3()
WEnd

Func Key1()
   Send("1")
   Sleep(150)
   Send("1")
   Sleep(150)
   Send("1")
EndFunc

Func Key2()
   Send(2)
   Sleep(150)
   Send(2)
   Sleep(150)
   Send(2)
EndFunc

Func Key3()
   Send(3)
   Sleep(150)
   Send(3)
   Sleep(150)
   Send(3)
EndFunc

Whats going on ?

 

Share this post


Link to post
Share on other sites
AutID

Rad help files for more.

HotKeySet("{a}", "Key1")
HotKeySet("{w}", "Key2")
HotKeySet("{t}", "Key3")
HotKeySet("{e}", "_exit")
;---------------------------------------
While 1
Sleep(10)
WEnd

Func Key1()
Send("1")
Sleep(150)
Send("1")
Sleep(150)
Send("1")
EndFunc

Func Key2()
Send(2)
Sleep(150)
Send(2)
Sleep(150)
Send(2)
EndFunc

Func Key3()
Send(3)
Sleep(150)
Send(3)
Sleep(150)
Send(3)
EndFunc

Func _exit()
Exit
EndFunc

Share this post


Link to post
Share on other sites
water

Whips87,

please enclose your AutoIt script in code tags. The editor has a blue "A" iconfor that. Thanks.

BTW:

Which program do you try to automate? Send isn't very reliable. There might be better ways to do what you want to do.


My UDFs and Tutorials:

Spoiler

UDFs:
Active Directory (NEW 2018-12-03 - Version 1.4.11.0) - Download - General Help & Support - Example Scripts - Wiki
OutlookEX (2018-10-31 - Version 1.3.4.1) - Download - General Help & Support - Example Scripts - Wiki
ExcelChart (2017-07-21 - Version 0.4.0.1) - Download - General Help & Support - Example Scripts
PowerPoint (2017-06-06 - Version 0.0.5.0) - Download - General Help & Support
Excel - Example Scripts - Wiki
Word - Wiki
 
Tutorials:

ADO - Wiki

 

Share this post


Link to post
Share on other sites
water

And could you please give your threads a more meaningful title? Every user on this forum is searching for help ;)


My UDFs and Tutorials:

Spoiler

UDFs:
Active Directory (NEW 2018-12-03 - Version 1.4.11.0) - Download - General Help & Support - Example Scripts - Wiki
OutlookEX (2018-10-31 - Version 1.3.4.1) - Download - General Help & Support - Example Scripts - Wiki
ExcelChart (2017-07-21 - Version 0.4.0.1) - Download - General Help & Support - Example Scripts
PowerPoint (2017-06-06 - Version 0.0.5.0) - Download - General Help & Support
Excel - Example Scripts - Wiki
Word - Wiki
 
Tutorials:

ADO - Wiki

 

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  

×