AutoHotkey Homepage AutoHotkey Community
Let's help each other out
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

Easy question but I'm a newbie....

 
Post new topic   Reply to topic    AutoHotkey Community Forum Index -> Ask for Help
View previous topic :: View next topic  
Author Message
Whinub
Guest





PostPosted: Tue Apr 24, 2007 7:57 pm    Post subject: Easy question but I'm a newbie.... Reply with quote

I'm currently working on a script where a variable needs to be increased by one after every loop and needs to be typed somewhere on screen...if someone could quickly type this up so that i could added to my script it would be greatly appreciated. Thanks in advance
Back to top
engunneer



Joined: 30 Aug 2005
Posts: 6856
Location: Pacific Northwest, US

PostPosted: Tue Apr 24, 2007 8:06 pm    Post subject: Reply with quote

You should post in the ask for help section. This section is for completed scripts. [Moderator's note: Moved]

as far as a variable increasing inside a loop, the built in variable A_index will probably do what you need. otherwise, you can increment the variable with ++
_________________
Unless otherwise noted, all code is untested.
Common Answers: 1.(Loops, Viruses, etc.) 2. Search 3.RTFM
Back to top
View user's profile Send private message Visit poster's website
MsgBox



Joined: 17 Nov 2005
Posts: 179
Location: Leicester, UK

PostPosted: Tue Apr 24, 2007 9:08 pm    Post subject: Reply with quote

ie.
Code:
Loop 10
{
   c := A_Index
   MsgBox % c
   }

or

Loop 10
{
   c++
   MsgBox % c
   }

and

Loop
{
   c++
   MsgBox Number - %c%
   IfGreater c, 9, Break
   }

...etc.

Hope that helps. Smile
Back to top
View user's profile Send private message Visit poster's website
Display posts from previous:   
Post new topic   Reply to topic    AutoHotkey Community Forum Index -> Ask for Help All times are GMT
Page 1 of 1

 
Jump to:  
You can post new topics in this forum
You can reply to topics in this forum


Powered by phpBB © 2001, 2005 phpBB Group