Search found 21 matches

by chango
04 Apr 2018, 13:08
Forum: Ask For Help
Topic: Delete value in array after use question
Replies: 7
Views: 442

Re: Delete value in array after use question

Xtra wrote:counter++ increments the counting of the number of non-empty values we are going to write to the file.
If there are no values it does not count them.
If there is nothing counted it skips writing to file which would be a blank line.

HTH
Hi Xtra , is it a method or function or is it a variable ?
by chango
04 Apr 2018, 10:59
Forum: Ask For Help
Topic: Delete value in array after use question
Replies: 7
Views: 442

Re: Delete value in array after use question

I'm having a problem working out what this part of the code is

counter++

I dont understand what it is ?
by chango
26 Mar 2018, 14:37
Forum: Ask For Help
Topic: Random and functions ?
Replies: 2
Views: 280

Re: Random and functions ?

BoBo wrote:

Code: Select all

Sleep % Rand(30,60)
SoundBeep
Sleep % Rand(15,30)
SoundBeep
Sleep % Rand(0.5,2)
SoundBeep
MsgBox % Rand(200,300)
F12::MouseMove, Rand(0,A_ScreenWidth), Rand(0,A_ScreenHeight)

Rand(min,max) {
    Random, res, min, max
    Return res * 1000
    }
Not tested.
Thanks I'll try this out :)
by chango
26 Mar 2018, 10:39
Forum: Ask For Help
Topic: Random and functions ?
Replies: 2
Views: 280

Random and functions ?

I didn't know what to put in the title sorry.. What I have is a random number ( used for a random time of pause) generated using Random.. which works great . Random, RandPause30to60, 30000, 60000 Sleep, %RandPause30to60% I'm trying to pair down the code as I find myself having to Run the Random gene...
by chango
18 Mar 2018, 16:47
Forum: Ask For Help
Topic: Delete value in array after use question
Replies: 7
Views: 442

Re: Delete value in array after use question

Not tested: #NoEnv OnExit, saveDataAndExit ; auto save fileName := "C:\Users\Administrator\Documents\text_text.txt" ; Original file tempName := "C:\Users\Administrator\Documents\text_text.tmp" ; Temp file Read_file: emails := EmailsArray := "" ; Clear if FileExist(tempName) { FileRead, emails, % te...
by chango
18 Mar 2018, 15:04
Forum: Ask For Help
Topic: Delete value in array after use question
Replies: 7
Views: 442

Delete value in array after use question

Hi folks, I have a very simple piece of code that opens a text file writes the contents line by line into an array. Read_file: emails := "" Loop, Read, C:\Users\Administrator\Documents\text_text.txt { emails .= A_loopReadLineA_Space } EmailsArray := [] Loop, Parse, emails, %A_Space% { EmailsArray.Pu...
by chango
15 Mar 2018, 10:45
Forum: Ask For Help
Topic: Random array sometimes parses nothing ? Topic is solved
Replies: 4
Views: 302

Re: Random array sometimes parses nothing ? Topic is solved

That's crazy :wtf: I just copied your code to test it and it works with the typo: AtArray4 := ["1","2","3","4","5"] Loop, 6 { Loop, 5 { Random, v%A_Index%, % AtArray4.MiniIndex(), % AtArray4.MaxIndex() } x%A_Index% = %v1%%v2%%v3%%v4%%v5% } msgbox %x1%`n%x2%`n%x3%`n%x4%`n%x5%`n%x6% ExitApp Returns: ...
by chango
15 Mar 2018, 10:32
Forum: Ask For Help
Topic: Random array sometimes parses nothing ? Topic is solved
Replies: 4
Views: 302

Re: Random array sometimes parses nothing ? Topic is solved

Odlanir wrote:You have a typo in your code, should be:

Code: Select all

AtArray4.MinIndex()
That did it .. so many thanks Odlanir :)
by chango
15 Mar 2018, 10:15
Forum: Ask For Help
Topic: Random array sometimes parses nothing ? Topic is solved
Replies: 4
Views: 302

Random array sometimes parses nothing ? Topic is solved

I have made and used some random output to text arrays with help from the forum. What I have found is that sometimes the array out puts nothing randomly the carries on and outputs the next array value fine. I'm using this : AtArray4 := ["1 ","2 ","3 ","4 "] Random, Rand, % AtArray4.MiniIndex(), % At...
by chango
27 Jul 2017, 15:19
Forum: Ask For Help
Topic: image detection and click above
Replies: 1
Views: 224

image detection and click above

Hi, I've had a lot of success with AHK, but I'm having a bit of trouble trying to work out how , after I find an image the mouse moves exactly.. so many pixels / mm etc above it and then clicks. I don't want it to find a second image as the same image appears everytime, but the image I'm searching f...
by chango
31 May 2017, 19:38
Forum: Ask For Help
Topic: I made a video about my question
Replies: 8
Views: 1011

Re: I made a video about my question

What I have been doing to get to grips with ahk is using Pulover's macro maker, I'm not a programmer never will be, but my approach is simple, I record what I want to do and then go through the code of the script it creates and attempt to simplify it. Now after only 5 days I'm using com's and expres...
by chango
31 May 2017, 16:20
Forum: Ask For Help
Topic: Random output of an array question Topic is solved
Replies: 2
Views: 328

Re: Random output of an array question Topic is solved

Holy Batman that worked straight out of the box !! ... fantastic community here... thanks very much TheDewd :)
by chango
31 May 2017, 14:22
Forum: Ask For Help
Topic: Random output of an array question Topic is solved
Replies: 2
Views: 328

Random output of an array question Topic is solved

Hi is there, a way of randomising what string comes out of an array?
I want to put X amount of strings in an array and then randomly have one of the strings become equal to a variable for output.
by chango
28 May 2017, 09:38
Forum: Pulovers Macro Creator
Topic: Random loop
Replies: 6
Views: 1974

Re: Random loop

I think because its easier for people who have no programming experience to use a GUI , and then you can export it to a akh script, and then like me work on that script. I did solve the problem and thanks to your reply because it pointed me to the right expression, implementing in the macro maker wa...
by chango
27 May 2017, 20:53
Forum: Pulovers Macro Creator
Topic: How do I Use The interface ?
Replies: 1
Views: 754

Re: How do I Use The interface ?

Youtube search Pulovers Macro Creator
by chango
27 May 2017, 18:31
Forum: Pulovers Macro Creator
Topic: Pulover's Macro Creator v5.0.5 - The Complete Automation Tool
Replies: 981
Views: 506883

Re: Pulover's Macro Creator v5.0.5 - The Complete Automation Tool

Ok I found it dohhh Use the Random command in the Run / File / String / Misc. window to generate a random number. The command will save the number inside a variable of your choice. Use this variable inside commands like Sleep enclosed in percent signs, e.g. %Rand% and directly inside functions and e...
by chango
27 May 2017, 18:22
Forum: Pulovers Macro Creator
Topic: Pulover's Macro Creator v5.0.5 - The Complete Automation Tool
Replies: 981
Views: 506883

Re: Pulover's Macro Creator v5.0.5 - The Complete Automation Tool

I cant seem to find the "rand" function in Pulover's macro maker can anyone help ?
by chango
27 May 2017, 17:29
Forum: Pulovers Macro Creator
Topic: Random loop
Replies: 6
Views: 1974

Re: Random loop

Hi does anyone know how to implement this in Pulover's macro maker please ?
by chango
27 May 2017, 14:36
Forum: Pulovers Macro Creator
Topic: Random loop
Replies: 6
Views: 1974

Re: Random loop

You can use the Random function to generate a random number, then use that in your loop. Something like this: Random, rand, 1, 10 ; random number between 1 and 10 Loop, %rand% { ; loop contents } Thanks neomulemi6, im testing it now, the macro creator implements the variables in a different way to ...

Go to advanced search