Search found 1376 matches
- 13 Jun 2018, 00:20
- Forum: Ask for Help (v1)
- Topic: ^+Backspace:: inside of ^+Backspace::
- Replies: 8
- Views: 1511
Re: ^+Backspace:: inside of ^+Backspace::
do you think following style is better? this stack directives right? #IfWinActive,Visual Studio Code #IfWinActive,ahk_class Chrome_WidgetWin_1 No . Directives do not stack like that. I'm saying the way you have it set up doesn't work like you think it does. The line I gave you DOES stack all the id...
- 13 Jun 2018, 00:05
- Forum: Ask for Help (v1)
- Topic: ^+Backspace:: inside of ^+Backspace::
- Replies: 8
- Views: 1511
Re: ^+Backspace:: inside of ^+Backspace::
Are you trying to stack directives? That's not how that works. Only the last one will take effect, which would be ahk_exe Code.exe in this case. WinTitle may contain more than one identifier, though. #if winActive("Visual Studio Code ahk_class Chrome_WidgetWin_1 ahk_exe Code.exe") ... #if ; remove d...
- 11 Jun 2018, 03:02
- Forum: Ask for Help (v1)
- Topic: Ansi VS Unicode
- Replies: 20
- Views: 7498
Re: Ansi VS Unicode
Unicode AHK requires UTF-8 files that have a BOM.DataLife wrote:When I compiled my code as Unicode all I did was install the Unicode version of AutoHotkey and then compile. Should I have saved my script as Unicode or UTF8 before compiling with the Unicode version of Autohotkey?
- 11 Jun 2018, 02:54
- Forum: Ask for Help (v1)
- Topic: Multiple Ocurrences on RegExMatch?
- Replies: 14
- Views: 3082
Re: Multiple Ocurrences on RegExMatch?
A loop. But a better way would to use a file-reading loop, then have each line processed based on line number (considering they're in a predictable order). You can use your own counting rather than the actual line numbers, so you can skip blank lines and use the separator to reset the count.
- 10 Jun 2018, 23:33
- Forum: Ask for Help (v1)
- Topic: Why wont this If statement work properly? Topic is solved
- Replies: 5
- Views: 1106
Re: Why wont this If statement work properly? Topic is solved
This is because of your incorrect use of syntax. If statements use expression-style syntax, while commands usually use traditional. Traditional calls for % delimiters, while using % delimiters in expression is a double-dereference, which means it's using the contents of the variable as a variable. L...
- 07 Jun 2018, 06:29
- Forum: Ask for Help (v1)
- Topic: RegEx: get last result (search backwards, search right-to-left)
- Replies: 6
- Views: 1421
Re: RegEx: get last result (search backwards, search right-to-left)
Reversing the needle shouldn't be as difficult as it comes off to be. strI could be used on the string to invert it, then you could manually fix the sequential things like .* and such. I've found it to be worth it due to the performance gain of doing an inverted search (on large strings) if the matc...
- 07 Jun 2018, 06:13
- Forum: Ask for Help (v1)
- Topic: RegEx: get last result (search backwards, search right-to-left)
- Replies: 6
- Views: 1421
Re: RegEx: get last result (search backwards, search right-to-left)
Searching right-to-left is as simple as inverting the strings. regExMatchI (requires strI)
- 06 Jun 2018, 09:56
- Forum: Gaming Help (v1)
- Topic: Global Var to Local Var?
- Replies: 1
- Views: 624
Re: Global Var to Local Var?
Local to what? Local vars only exist for functions/methods. If you want to make it a function, they would still need to be separated variables, unless you made 2 functions, but then that's poor, redundant code.
- 31 May 2018, 15:37
- Forum: Ask for Help (v1)
- Topic: Double left mouse click remap
- Replies: 5
- Views: 1735
Re: Double left mouse click remap
This is true. Thanks for the catch, it's been a long day
I've edited my post.
![Razz :P](./images/smilies/icon_razz.gif)
- 31 May 2018, 15:12
- Forum: Ask for Help (v1)
- Topic: Double left mouse click remap
- Replies: 5
- Views: 1735
Re: Double left mouse click remap
Yes, you can fix that, but it depends on how exactly you want it to work. If you want it to work globally, minus specific windows, you could make an exception list. Alternatively, you could make it work only with a specific list of windows. #if !winActive("Accounting Software") ; replace title as ne...
- 30 May 2018, 16:05
- Forum: Ask for Help (v1)
- Topic: Double left mouse click remap
- Replies: 5
- Views: 1735
Re: Double left mouse click remap
Code: Select all
Enter::click 2
- 17 May 2018, 08:40
- Forum: Ask for Help (v1)
- Topic: Discord
- Replies: 2
- Views: 8006
Re: Discord
The official Discord channel can be found here: https://autohotkey.com/boards/viewtopic.php?f=5&t=59
- 12 May 2018, 01:41
- Forum: Scripts and Functions (v1)
- Topic: ScriptUp - Many scripts, One process
- Replies: 36
- Views: 11211
Re: ScriptUp - Many scripts, One process
Hey everyone, I've got some news! First, I pushed a minor update: you can now right-click scripts in the list and choose "Edit" to have the script open in your default editor (whatever you have set for when you right-click > Edit a script file). Second, I'm working on a new version. Here's a few of ...
- 11 May 2018, 22:17
- Forum: Ask for Help (v1)
- Topic: Partial Title Match with IfWinActive Topic is solved
- Replies: 2
- Views: 4567
Re: Partial Title Match with IfWinActive Topic is solved
I'm not sure if they're actually considered deprecated, but I've deprecated IfWinActive/IfWinNotActive in my mind. Try the following: setTitleMatchMode,2 F1:: if(winActive("Mozilla Firefox")) msgbox Active else msgbox Not active return However, if you're not doing it by a changing title and want it ...
- 10 May 2018, 20:50
- Forum: Tips and Tricks (v1)
- Topic: The very powerful exception function
- Replies: 7
- Views: 5977
Re: The very powerful exception function
If someone could write a proper function I would be very grateful. I agree with Helgef. I don't see why your rendition would be considered improper. this does require a little bit of overhead in designing your functions and thinking ahead of the possible errors to throw I usually write the function...
- 10 May 2018, 03:57
- Forum: Ask for Help (v1)
- Topic: Help with Count++ in my script
- Replies: 6
- Views: 2564
Re: Help with Count++ in my script
Taking a guess here.. Always sending x, but sending a every time x is sent ten times (plus a 1-second sleep)?
Note: count++ isn't a command, it's a post-increment on variable count.
Code: Select all
F10::
loop {
send x
if(!mod(a_index,10)){
send a
sleep 1000
}
sleep 50
}
return
- 09 May 2018, 19:16
- Forum: Ask for Help (v1)
- Topic: Simple "if WinActive" scripts not working
- Replies: 4
- Views: 1153
Re: Simple "if WinActive" scripts not working
That would be due to your hotkey. When you initially start a script, it will run top-to-bottom until it hits a return, exit, exitApp, hotstring, or hotkey (might be others I'm not thinking of as well..). Meaning, it hits that hotkey and stops executing sequential lines, making your if unreachable. S...
- 09 May 2018, 18:38
- Forum: Tips and Tricks (v1)
- Topic: The very powerful exception function
- Replies: 7
- Views: 5977
Re: The very powerful exception function
While bugs happen infrequently for me (I'm kind of a perfectionist, I suppose), your stack functions are great! I'll definitely be using them, thanks ![Thumbup :thumbup:](./images/smilies/icon_thumbup.gif)
![Thumbup :thumbup:](./images/smilies/icon_thumbup.gif)
- 09 May 2018, 17:55
- Forum: Scripts and Functions (v1)
- Topic: Changing Control Background/Text Color
- Replies: 11
- Views: 3194
Re: Changing Control Background/Text Color
Yep, there it is. I was just tired and didn't go looking for it
Thanks guest3456, updated main example
![Wink ;)](./images/smilies/icon_e_wink.gif)
- 08 May 2018, 19:29
- Forum: Scripts and Functions (v1)
- Topic: Changing Control Background/Text Color
- Replies: 11
- Views: 3194
Re: Changing Control Background/Text Color
Yeah, destroying a GUI and recreating it over is very inefficient, and significantly more so if it's a complicated GUI. But, you gave me an idea! I had tried gui,cancel,nohide , which didn't work. However, actually hiding it then showing it again does in fact work. Again, not a great solution, more ...