Search found 16835 matches

by boiler
Today, 08:18
Forum: Ask for Help (v2)
Topic: AHK can't recognize paths with space properly. Run("C:\Users\..\code.exe" "C:\Users\hello world.ahk) will open two files
Replies: 3
Views: 69

Re: AHK can't recognize paths with space properly. Run("C:\Users\..\code.exe" "C:\Users\hello world.ahk) will open two f

alawsareps — You already asked and got an answer to basically the same question a little earlier here . Why are creating multiple threads asking the same questions? If you didn’t understand the answer in the earlier thread, follow up with another question in that thread. Don’t create a whole new th...
by boiler
Today, 08:03
Forum: Ask for Help (v2)
Topic: Generating part of a variable
Replies: 1
Views: 32

Re: Generating part of a variable

#Requires AutoHotkey v2.0 FFB := [ {var1: "65", var2: "100", var3: "100", var4: "100", var5: "100", var6: "900"}, {var1: "75", var2: "100", var3: "100", var4: "0", var5: "0", var6: "900"}, {var1: "75", var2: "100", var3: "100", var4: "0", var5: "0", var6: "900"}, {var1: "75", var2: "100", var3: "10...
by boiler
Today, 06:13
Forum: Ask for Help (v2)
Topic: Copy predefined text to Win 11 copy history. Topic is solved
Replies: 2
Views: 35

Re: Copy predefined text to Win 11 copy history. Topic is solved

There are ways to achieve your goal of not having to remember a bunch of hotkeys in AHK without bothering with the clipboard history. It would be very straightforward to have a script produce a menu of your 10 items when you press a hotkey, and you would click on any of them to send that text. Or ma...
by boiler
Today, 00:25
Forum: Ask for Help (v2)
Topic: I want to open in VSCODE any file I copied. Code doesn't work: Run("C:\Users\jethr\...\Code.exe" "%A_Clipboard%")
Replies: 1
Views: 127

Re: I want to open in VSCODE any file I copied. Code doesn't work: Run("C:\Users\jethr\...\Code.exe" "%A_Clipboard%")

You’re not using expression syntax correctly. First, you don’t put % around variables. And you don’t put variables inside quotes. And unlike legacy syntax in v1, you have not put quotes in the strings themselves and separated them with a space; you have concatenated two strings (that don’t contain a...
by boiler
Yesterday, 21:56
Forum: Ask for Help (v2)
Topic: Dock/Attach window function for AHK v2
Replies: 4
Views: 234

Re: Dock/Attach window function for AHK v2

Since everyone seems to be ignoring me. :cry: Well, the thread’s subject and first post is mainly about seeing who might want to translate a relatively involved script to v2, so most would probably stop reading there, and each lengthy post after that tends to turn away pretty much everyone else who...
by boiler
Yesterday, 21:23
Forum: Ask for Help (v2)
Topic: How to make AutoHotkey wait for a page to load?
Replies: 2
Views: 75

Re: How to make AutoHotkey wait for a page to load?

Note that your short AHK script is v1 but you posted in the v2 section. I’ll move the thread if you’re looking to use v1.
by boiler
Yesterday, 16:00
Forum: Ask for Help (v2)
Topic: Help with making manual hotkey for CTRL+C Topic is solved
Replies: 1
Views: 87

Re: Help with making manual hotkey for CTRL+C Topic is solved

Try this, assuming the "Copy" menu item is the second item starting with a "C" (with "Cut" being the first):

Code: Select all

#Requires AutoHotkey v2.0

SetKeyDelay 20

#HotIf WinActive('ahk_exe MyPhoneExplorer.exe') ; assuming that's the actual process name
^c::SendEvent '{Click R}cc{Enter}'
by boiler
Yesterday, 15:35
Forum: Gaming Help (v1)
Topic: Help with dual boxing script...
Replies: 9
Views: 293

Re: Help with dual boxing script...

I have no idea why adding the quotes breaks the CoordMode, but it works this way so I don't care LoL Well, I'll explain it anyway so hopefully you don't have to ask again to fix similar issues in the future: You don't quote literal strings in legacy/command syntax. That's only in expressions. If yo...
by boiler
25 Apr 2024, 07:56
Forum: Gaming Help (v1)
Topic: Problem with a WinActive and WinNotExist loop script
Replies: 9
Views: 132

Re: Problem with a WinActive and WinNotExist loop script

That's really it. It's not an AHK limitation. No other tool would be able to send keystrokes in a way that will get it to accept them, if that's really the issue here. It's the way the app works. I could easily write a little app that will only respond to keystrokes when its window is active and the...
by boiler
25 Apr 2024, 06:46
Forum: Gaming Help (v1)
Topic: Problem with a WinActive and WinNotExist loop script
Replies: 9
Views: 132

Re: Problem with a WinActive and WinNotExist loop script

And with the minimized windows maybe not, just Not Active windows, in the second monitor in Borderless Windowed, should it work too? or with another cmd? Should it work? As I had posted earlier: Not all windows respond to virtual key presses, and even when they do, some don’t respond to virtual key...
by boiler
25 Apr 2024, 06:39
Forum: Ask for Help (v2)
Topic: How can I make a macro to paste and send an image every 300 seconds in Discord?
Replies: 3
Views: 125

Re: How can I make a macro to paste and send an image every 300 seconds in Discord?

I would think that an automatic posting of a message every few minutes would be frowned upon if not outright disallowed. @runie, this sounds like something that would definitely be not be allowed on the AHK Discord. Would that be true in general?
by boiler
25 Apr 2024, 06:13
Forum: Gaming Help (v1)
Topic: Problem with a WinActive and WinNotExist loop script
Replies: 9
Views: 132

Re: Problem with a WinActive and WinNotExist loop script

Again, hard-coding the PID is not the way to go because it changes every time you run the app. And you didn’t say before that you want to send it to a minimized window. I don’t expect you’d ever get that to work with any approach.
by boiler
25 Apr 2024, 05:52
Forum: Ask for Help (v2)
Topic: How to iterate through list of colors
Replies: 1
Views: 44

Re: How to iterate through list of colors

That’s not an object with key-value pairs. That’s an object with a bunch of properties defined. It looks like you are wanting to do the same as a v1 associative array, which in v2 is a map object : Basic := [211, 211, 221] Rare := [190, 254, 167] Epic := [158, 240, 255] Legendary := [255, 212, 163] ...
by boiler
25 Apr 2024, 05:22
Forum: Ask for Help (v2)
Topic: Fat-arrow function after auto-exec part Topic is solved
Replies: 4
Views: 91

Re: Fat-arrow function after auto-exec part Topic is solved

Both functions are defined as soon as the script runs, but assigning a function reference to a variable only happens if you execute the line that does so, and your script would never execute that line. That is fully expected as that very concept is explained in the documentation of the fat-arrow fun...
by boiler
25 Apr 2024, 05:03
Forum: Ask for Help (v2)
Topic: Fat-arrow function after auto-exec part Topic is solved
Replies: 4
Views: 91

Re: Fat-arrow function after auto-exec part Topic is solved

Put the line where you assign f where it actually executes (above the return ) and it will work fine. That exact info is in the warning message itself, by the way. The function definition occurs as soon as the script runs, but the assignment of the function reference only occurs if/when you execute ...
by boiler
25 Apr 2024, 04:33
Forum: Off-topic Discussion
Topic: « What's on your mind? » Topic is solved
Replies: 4897
Views: 1398778

Re: « What's on your mind? » Topic is solved

In other words, 55/69 out of 69 vendors say it’s safe, and as you’ve pointed out, there’s no convincing some of them because they have no interest in being logical about it. Because AHK can/has been used to create malware, therefore AHK should be flagged is the kind of intellectual dishonesty that e...
by boiler
24 Apr 2024, 22:03
Forum: Gaming Help (v1)
Topic: Problem with a WinActive and WinNotExist loop script
Replies: 9
Views: 132

Re: Problem with a WinActive and WinNotExist loop script

Are you really meaning that you want to differentiate between the windows? Get the HWND (unique window IDs) of both windows using WinGet…List . If you need to know which one is which, you can compare the window positions or track as each one is opened, or potentially many other aspects that would di...
by boiler
24 Apr 2024, 20:29
Forum: Ask for Help (v1)
Topic: Dynamic way to find a program and run it Topic is solved
Replies: 2
Views: 133

Re: Dynamic way to find a program and run it Topic is solved

I've went through some post on the forum, and it seems like they require the folder window to be active to do the search, is there a way to search for a specific .exe file and run it without requiring a window to be active? I don’t know what you saw that made you think a folder window had to be act...
by boiler
24 Apr 2024, 13:10
Forum: Scripts and Functions (v2)
Topic: Class ToolTipOptions - 2024-03-27
Replies: 29
Views: 3573

Re: Class ToolTipOptions - 2024-03-27

Bobak -- With some trial and error, I have found that you can't just change the options once they're set. You have to .Reset() and then .Init() again in order to have it recognize the new options, as this code demonstrates: #Requires AutoHotkey v2.0 #Include <ToolTipOptions> ; use first set of opti...
by boiler
24 Apr 2024, 09:52
Forum: Gaming
Topic: Help with making code for keyboard input to controller Topic is solved
Replies: 6
Views: 97

Re: Help with making code for keyboard input to controller Topic is solved

I am sure AHK can do this, or some other program. I tried using UCR and Interception .. not sure how it all worked, tried to make it work, but couldnt. So maybe an AHK code could be made? Any help would be great thank you. Native AHK cannot do this. Controller button presses and other inputs cannot...

Go to advanced search