Search found 24 matches
- 12 Apr 2019, 11:38
- Forum: Forum Issues
- Topic: fix this!!!
- Replies: 66
- Views: 17213
- 12 Apr 2019, 01:54
- Forum: Ask for Help (v1)
- Topic: Trouble understanding callback function's args by address
- Replies: 7
- Views: 1669
Trouble understanding callback function's args by address
So here's what the docs have to offer about it: https://autohotkey.com/docs/commands/RegisterCallback.htm#Indirect I don't understand why would would add or subtract A_PtrSize from the args. What does this do? Also, adding +0 is just for ensuring that it's purely numeric, and not a numeric string, r...
- 27 Feb 2019, 15:22
- Forum: Bug Reports
- Topic: Bug in Hotstring() function, executing labels Topic is solved
- Replies: 1
- Views: 1115
Bug in Hotstring() function, executing labels Topic is solved
Hotstring(":X:test123", "TestLabel")
return
TestLabel:
MsgBox, hi
return
Labels are not recongnized as labels, even though the option X is present.
Broke in the latest AHK update.
return
TestLabel:
MsgBox, hi
return
Labels are not recongnized as labels, even though the option X is present.
Broke in the latest AHK update.
- 16 Aug 2018, 04:28
- Forum: Ask for Help (v1)
- Topic: Slowing down the next key press Topic is solved
- Replies: 2
- Views: 574
Re: Slowing down the next key press Topic is solved
Use Sleep.
You can also Sleep inline
EDIT: Oh he got it already. Before he edited his post he was trying to use Pause, so that's why I replied with Sleep.
You can also Sleep inline
Code: Select all
SendInput, 0{Sleep 500}000
- 28 Jun 2018, 19:16
- Forum: Ask for Help (v1)
- Topic: Need help with super basic script. (data entry and send keystrokes) Topic is solved
- Replies: 2
- Views: 843
Re: Need help with super basic script. (data entry and send keystrokes) Topic is solved
Look into Gui , you're specifically going to want to be adding an Edit and I can also recommend SmartGuiXP for easily building your GUIs Example line of code to add an Edit along with a variable "Variable1" to which the input from your Edit will be saved to: Gui, Add, Edit, x2 y5 w50 h20 -Multi vVar...
- 20 Jun 2018, 14:42
- Forum: Ask for Help (v1)
- Topic: Splitting a string into multiple lines with a maximum lenght Topic is solved
- Replies: 14
- Views: 4932
Re: Splitting a string into multiple lines with a maximum lenght Topic is solved
I know this has already been "solved" but it was also solved long ago in the library below. String Things https://autohotkey.com/boards/viewtopic.php?t=53 It contains this function: /* WordWrap Wrap the specified text so each line is never more than a specified length. Unlike st_lineWrap(), this fu...
- 20 Jun 2018, 14:42
- Forum: Ask for Help (v1)
- Topic: Splitting a string into multiple lines with a maximum lenght Topic is solved
- Replies: 14
- Views: 4932
Re: Splitting a string into multiple lines with a maximum lenght Topic is solved
attempt 2: used recursion example1 = ( comment For an example, this thing that I am writing right now needs to be split into ; 77 chars multiple lines, and lets say each line can be a maximum of 80 characters. So ; 76 chars I'm going to do this manually, look below this block of text to see what I ...
- 20 Jun 2018, 04:52
- Forum: Ask for Help (v1)
- Topic: Splitting a string into multiple lines with a maximum lenght Topic is solved
- Replies: 14
- Views: 4932
Re: Splitting a string into multiple lines with a maximum lenght Topic is solved
#NoEnv #SingleInstance Force #Persistent SetBatchLines -1 haystack = (LTrim Join`n For an example, this thing that I am writing right now needs to be split into multiple lines, and heres a new line in here, and lets say each line can be a maximum of 80 characters. So I'm going to do this manually, ...
- 20 Jun 2018, 04:38
- Forum: Ask for Help (v1)
- Topic: Splitting a string into multiple lines with a maximum lenght Topic is solved
- Replies: 14
- Views: 4932
Re: Splitting a string into multiple lines with a maximum lenght Topic is solved
Hi, Meow I'm late to the party and I have knitted together this first attempt: First example from OP has many tabs, not sure how to handle Second example, also from OP, ignores stuff behind the semicolon third example from your later post example1 = ( For an example, this thing that I am writing ri...
- 19 Jun 2018, 19:51
- Forum: Ask for Help (v1)
- Topic: Splitting a string into multiple lines with a maximum lenght Topic is solved
- Replies: 14
- Views: 4932
Re: Splitting a string into multiple lines with a maximum lenght Topic is solved
I did something like this here, it uses InStr to find the first occurrence of a string before the nth character. To search backwards you have to convert the character index to a negative (or zero) index that InStr can handle. Edit some text files, string length - AutoHotkey Community https://autoho...
- 19 Jun 2018, 19:49
- Forum: Ask for Help (v1)
- Topic: Splitting a string into multiple lines with a maximum lenght Topic is solved
- Replies: 14
- Views: 4932
Re: Splitting a string into multiple lines with a maximum lenght Topic is solved
#NoEnv #SingleInstance Force #Persistent SetBatchLines -1 haystack = (LTrim Join`n For an example, this thing that I am writing right now needs to be split into multiple lines, and heres a new line in here, and lets say each line can be a maximum of 80 characters. So I'm going to do this manually, ...
- 19 Jun 2018, 15:27
- Forum: Ask for Help (v1)
- Topic: Splitting a string into multiple lines with a maximum lenght Topic is solved
- Replies: 14
- Views: 4932
Re: Splitting a string into multiple lines with a maximum lenght Topic is solved
This should do it: TooLong := "For an example, this thing that I am writing right now needs to be split into `; 77 chars" ; Note that the semi-colon need to be excaped. ShortString := "" MaxLen := 80 OrgiLen := StrLen(TooLong) LastChar := 1 Loop { If (LastChar >= OrgiLen) ; There are no more linefe...
- 18 Jun 2018, 21:15
- Forum: Ask for Help (v1)
- Topic: Splitting a string into multiple lines with a maximum lenght Topic is solved
- Replies: 14
- Views: 4932
Splitting a string into multiple lines with a maximum lenght Topic is solved
Hi, So I'm looking to split a long string into array elements, and each element in the array can only be a maximum of x characters long. Sounds simple enough, right? But here's the tricky part: I also don't want it to break up words. So it wouldn't start a new line just in the middle of a word awkwa...
- 31 Mar 2017, 12:54
- Forum: Ask for Help (v1)
- Topic: Coordinates relative to an inactive window Topic is solved
- Replies: 3
- Views: 1918
Re: Coordinates relative to an inactive window Topic is solved
First retrieves the position of the inactive window by means of WinGetPos command and make the inactive window upper-left corner coordinates function as reference from wich start your pixel research. CoordMode, Pixel, Screen YourRectangle := {"width": 400, "height": 300} ; for exemple WinGetPos, XS...
- 31 Mar 2017, 12:09
- Forum: Ask for Help (v1)
- Topic: Coordinates relative to an inactive window Topic is solved
- Replies: 3
- Views: 1918
Coordinates relative to an inactive window Topic is solved
Hi, So what I need is to be able to do a PixelSearch on an inactive window (I check with a loop every few seconds if one specific item has disappeared from my inventory (for a game)) but I can't figure out how I could get the coordinates to be relative to an inactive window. So when I use PixelSearc...
- 28 Jan 2017, 07:24
- Forum: Ask for Help (v1)
- Topic: Changing SystemParametersInfo dll values Topic is solved
- Replies: 2
- Views: 973
Re: Changing SystemParametersInfo dll values Topic is solved
Works! Thank you so much, you have no idea how much I appreciate thisHotKeyIt wrote:There is an error in line 4, try changing it to: MK:=new _Struct(MOUSEKEYS),MK.cbSize:=sizeof(MK)
- 27 Jan 2017, 21:31
- Forum: Ask for Help (v1)
- Topic: Changing SystemParametersInfo dll values Topic is solved
- Replies: 2
- Views: 973
- 28 Oct 2016, 18:49
- Forum: Ask for Help (v1)
- Topic: Get a part of string from between characters
- Replies: 5
- Views: 1814
Re: Get a part of string from between characters
TestString := "http://www.insertforumnamehere.com/members/meow.12345/" PosPeriod := InStr(TestString, ".",, 0) ; 0 = right-to-left search PosSlash := InStr(TestString, "/",, 0) ; If the period wasn't found OR the slash wasn't found OR if the period is located after the last slash... if (!PosPeriod ...
- 28 Oct 2016, 17:51
- Forum: Ask for Help (v1)
- Topic: Get a part of string from between characters
- Replies: 5
- Views: 1814
Re: Get a part of string from between characters
If it's only numbers, and those are the only numbers, we can just do this actually: string:="http://www.insertforumnamehere.com/members/meow.12345/" RegExMatch(string,"\d+",id) MsgBox % id return \d means digits, and + means find one or more of them in a row. This would be trickier if there are num...
- 28 Oct 2016, 17:12
- Forum: Ask for Help (v1)
- Topic: Get a part of string from between characters
- Replies: 5
- Views: 1814
Get a part of string from between characters
So, I want to to be able to get a number from a string. The number can be random length. (The number in my case is a user id for a forum) So lets say I'd want to get the user id from a link like this http://www.insertforumnamehere.com/members/meow.12345/ What I want are the numbers "685006". So the ...