Search found 2872 matches

by Exaskryz
Yesterday, 12:37
Forum: Ask For Help
Topic: [Solved] Sending 2 different action when a key is pressed + when it’s released Topic is solved
Replies: 4
Views: 53

Re: Sending an action when a key is pressed + when a key is released Topic is solved

MButton can be finicky, but the code should be

Code: [Select all]GeSHi © Codebox Plus

MButton down::SoundSet, 0,, Mute, 2
MButton up::SoundSet, 1,, Mute, 2



If it doesn't work as is, try a different key instead of MButton, just to test it. Then we can come up with a different solution.
by Exaskryz
11 Sep 2018, 20:40
Forum: Ask For Help
Topic: Using IE COM, how can I scroll to bottom of page? Topic is solved
Replies: 4
Views: 44

Re: Using IE COM, how can I scroll to bottom of page? Topic is solved

It's complained about scroll and scrollTo if I omitted window, will start trialing those in any combination I can think of.

Edit: That worked straight away. Thanks!
by Exaskryz
11 Sep 2018, 20:32
Forum: Ask For Help
Topic: Using IE COM, how can I scroll to bottom of page? Topic is solved
Replies: 4
Views: 44

Re: Using IE COM, how can I scroll to bottom of page? Topic is solved

Didn't work: --------------------------- &Test Script.ahk --------------------------- Error: 0x80020006 - Unknown name. Specifically: window Line# 375: { 376: if (ex.Range("N" A_Index).DisplayFormat.Interior.Color != 6249471) 377: Continue 378: if (ex.Range("N" A_Index).value...
by Exaskryz
11 Sep 2018, 17:19
Forum: Ask For Help
Topic: Using IE COM, how can I scroll to bottom of page? Topic is solved
Replies: 4
Views: 44

Using IE COM, how can I scroll to bottom of page? Topic is solved

I could end up focusing the browser window and then using Send {End} , but for curiosity's sake, I'd like to get it done with COM. (It'd be slightly more fluid too, letting me do stuff in the meantime while I wait on webpages to load instead of having to leave it focused.) I've tried stuff like ie.s...
by Exaskryz
07 Sep 2018, 14:56
Forum: Ask For Help
Topic: round to nearest non-zero number
Replies: 5
Views: 87

Re: round to nearest non-zero number

Two improvements. Try in the RegEx method the needle "^0*\K\.0*" . The ^ means we must match the beginning of the string. 0.something will match, but 160.something will not. The 0* also lets .something, with no digits left of decimal match. The \K means all matching characters in pattern t...
by Exaskryz
07 Sep 2018, 08:56
Forum: Ask For Help
Topic: round to nearest non-zero number
Replies: 5
Views: 87

Re: round to nearest non-zero number

There's probably a way more efficient way. But you can identify how many 0s there are by using RegExMatch to extract the string of ".000..." for how many zeroes there are, then use the StrLen command to find how many positions to go. This counts the period in the strlen, but we want that, ...
by Exaskryz
30 Aug 2018, 22:05
Forum: Ask For Help
Topic: Loop with increments 1a, 1b, 1c, 2a, 2b, 2c, 3a etc
Replies: 5
Views: 107

Re: Loop with increments 1a, 1b, 1c, 2a, 2b, 2c, 3a etc

There's more than one way to solve this problem. Rather than any loop inside of a loop, here's an answer with a single loop. In a loop, you have the variable A_ Index . We will use this in conjunction with the Ceil () function (Ceil, rounds up) and the Mod () function (Modulus, calculates a remainde...
by Exaskryz
27 Aug 2018, 12:23
Forum: Ask For Help
Topic: If color=green then click x, y. So simple but doesnt work Topic is solved
Replies: 1
Views: 46

Re: If color=green then click x, y. So simple but doesnt work Topic is solved

(Foreword: I have not downloaded "Case Clicker.ahk", just using the reference code you copy and pasted to the forum.) First off, when you find the Target_Color matches Current_Color1, you are making it click at Target_X2 and _Y2, not _X1 and _Y1. May be purposeful, but I otherwise saw a pa...
by Exaskryz
02 Aug 2018, 19:41
Forum: Ask For Help
Topic: Binding a key for a Sequence
Replies: 2
Views: 87

Re: Binding a key for a Sequence

This is possible with a counting variable and an If statement. var:=0 ; start this at zero e:: var++ ; increments the variable by 1 If (var=1) Send 1 else if (var=2) Send 2 ; add in 3 and 4, to make sure you understand what is going on else if (var=5) { Send 5 var:=0 ; reset to zero } return You can...
by Exaskryz
26 Jun 2018, 14:39
Forum: Ask For Help
Topic: AHK with 2 programs?
Replies: 3
Views: 96

Re: AHK with 2 programs?

Reading through your post, I think you've got it. As far as I understand the #persitent thingie (does the #persistent make the stuff after it run nonstop?) # Persistent prevents the script from closing when it reaches the auto- execute section. Normally people start out with AHK using a Hotkey , whi...
by Exaskryz
25 Jun 2018, 15:16
Forum: Ask For Help
Topic: AHK with 2 programs?
Replies: 3
Views: 96

Re: AHK with 2 programs?

Here's a template, you will have to change this. Click on any links in the code to look at the documentation. Oh, it's not in the code, but check out CoordMode to make sure your coordinates are right between ImageSearch and Clicks. #Persistent SetTimer, Routine, 30000 ; checks every 30 seconds retur...
by Exaskryz
13 Jun 2018, 16:10
Forum: Forum Issues
Topic: +1 feature on the forum
Replies: 30
Views: 1200

Re: +1 feature on the forum

I would use a +1 at times. It'd be my way of saying "This post is quality", "It helps the user", "It is a great example", "It uses a good technique", etc. without bumping a thread.
by Exaskryz
13 Jun 2018, 16:08
Forum: Ask For Help
Topic: Hotkey
Replies: 4
Views: 92

Re: Hotkey

(Note: The first link is from the old forums, the second link is on these forums) http://www.autohotkey.com/board/topic/6 ... re-thread/ or https://autohotkey.com/boards/viewtopic.php?f=7&t=11952
by Exaskryz
09 Jun 2018, 00:56
Forum: Ask For Help
Topic: help with playing macro only once Topic is solved
Replies: 7
Views: 164

Re: help with playing macro only once Topic is solved

Use Qysh's code, but add KeyWait, \ before the return line. See KeyWait.
by Exaskryz
03 Jun 2018, 13:23
Forum: Ask For Help
Topic: For a simple CTRL+AX, should I make it longer so that AHK will have enough time to process?
Replies: 1
Views: 60

Re: For a simple CTRL+AX, should I make it longer so that AHK will have enough time to process?

It isn't necessarily that AHK needs time to process, but the target program does. AHK can send input to a program too fast for it to handle at times. You can try to avoid interlacing the Sleep, 100 by instead using SetKeyDelay . CTRLDOWN isn't a key, but CTRL is. You can use Send {Ctrl Down} and Sen...
by Exaskryz
02 Jun 2018, 16:46
Forum: Ask For Help
Topic: How to use different variables in the same "if"? Topic is solved
Replies: 7
Views: 181

Re: How to use different variables in the same "if"? Topic is solved

Looking at the direction you were taking OP, I'd do this.

Code: [Select all]GeSHi © Codebox Plus

If (cKey = "Main_B") OR (cKey = "Main_C") OR (cKey = "Main_D") ...
gosub, Last_Key


You could also use If var in to do

Code: [Select all]GeSHi © Codebox Plus

If cKey in Main_B,Main_C,Main_D,Main_E,Main_F
gosub, Last_Key
by Exaskryz
23 May 2018, 04:51
Forum: Ask For Help
Topic: Please help me with this code!1 I would greatly appreciate it!
Replies: 7
Views: 240

Re: please help me I really need it

You have the code structured just fine. I do encourage you to read over the documentation. And look over these couple posts that give you instructions on setting up an "autofire", even though yours is more complex. (Note: The first link is from the old forums, the second link is on these f...
by Exaskryz
15 May 2018, 16:44
Forum: Ask For Help
Topic: Can someone assist with this Loop statement?
Replies: 9
Views: 208

Re: Can someone assist with this Loop statement?

If WinExist vs IfWinExist.

You had it right in your "Else" statement.
by Exaskryz
14 May 2018, 08:14
Forum: Ask For Help
Topic: Really new to this, need help with macro
Replies: 2
Views: 110

Re: Really new to this, need help with macro

Ooh, I noticed that the Ctrl+Volume_Up hotkey ^Volume_Up:: does *not* work on my system as is. When I press the Ctrl key, it defaults to using the normal F1-F12 key functions. Take my keyboard as an example. F5 refreshes webpages, but I need to press Fn+F5 to get the F5 behavior. Otherwise, it does ...

Go to advanced search