Search found 6373 matches

by jeeswg
23 May 2019, 16:14
Forum: Ask For Help
Topic: same block code many times with small differents Topic is solved
Replies: 7
Views: 216

Re: same block code many times with small differents Topic is solved

I rarely see, in AHK or other languages, a form of loop used, where the break condition is after the main body of the loop. Where are you getting your information from?
by jeeswg
23 May 2019, 15:43
Forum: Ask For Help
Topic: same block code many times with small differents Topic is solved
Replies: 7
Views: 216

Re: same block code many times with small differents Topic is solved

I would probably do it like this: CoordMode, Pixel, Screen path := A_ScriptDir "\saj1.png" ImageWait(xset, yset, path) MouseClick, Left, % xset+5, % yset+5 ImageWait(ByRef xset, ByRef yset, path) { Loop { ImageSearch, xset, yset, 0, 0, 2731, 763, % "*30 " path if (ErrorLevel = 1) Sleep, 500 else if ...
by jeeswg
23 May 2019, 14:32
Forum: Ask For Help
Topic: USB mouse stops working after hibernating PC
Replies: 0
Views: 90

USB mouse stops working after hibernating PC

- I've recently started using the Hibernate feature on Windows 7. - Every time, after hibernating, my USB mouse has stopped working. - Unplugging the USB mouse, and plugging it back in again, has fixed the problem. Fortunately this did not crash the PC, this type of action is potentially risky. - I ...
by jeeswg
23 May 2019, 13:24
Forum: Ask For Help
Topic: Get WindowID by its fast or slow visible text
Replies: 5
Views: 208

Re: Get WindowID by its fast or slow visible text

Another issue is: if you save a script as UTF-8, save it with a BOM.
by jeeswg
23 May 2019, 12:41
Forum: Offtopic
Topic: « What's on your mind? »
Replies: 4193
Views: 630912

Re: « What's on your mind? »

Why are statues so bad nowadays? George Best statue mocked by fans - BBC News https://www.bbc.co.uk/news/uk-northern-ireland-48371633 Statue of comedian Victoria Wood unveiled - BBC News https://www.bbc.co.uk/news/av/uk-england-manchester-48314335/sculpture-of-comedian-victoria-wood-erected-in-bury ...
by jeeswg
23 May 2019, 12:33
Forum: Scripts and Functions
Topic: A simple "Console.log" for debugging or developping time.
Replies: 8
Views: 1014

Re: A simple "Console.log" for debugging or developping time.

I used a partial AHK v2 -> AHK v1 converter, which I will release ..., and I double-checked other lines. It might work as is, possibly you need to check the Hotkey command, and/or other lines. Cheers. /* ; AHK v1.1 global Console := new CConsole Console.hotkey := "^+c" ; to show the console Console....
by jeeswg
23 May 2019, 10:13
Forum: Ask For Help
Topic: Fastest way to loop through Folders
Replies: 9
Views: 245

Re: Fastest way to loop through Folders

One thing to note is that: doing one search can take a long time, but repeating that search immediately after, can be instant. I suppose because everything is cached.
by jeeswg
22 May 2019, 08:14
Forum: Wish List
Topic: A_BIF.XXX(): redefine but access built-in functions
Replies: 4
Views: 338

A_BIF.XXX(): redefine but access built-in functions

It would be immensely useful, in AHK v1/v2, if we could redefine a built-in function, but maintain access to the original. Would it be difficult to implement this? A related point would be some kind of IsPassed function, to know if a particular parameter had been passed. Here are some examples: ;A_B...
by jeeswg
21 May 2019, 17:43
Forum: C/C++
Topic: C++: AHK source code: append number to array
Replies: 2
Views: 240

Re: C++: AHK source code: append number to array

- Fair points re. the Range object, I've updated the post to provide an enumerator object version. - That said, I tested my original function, and it worked great at 1 million keys, and reasonably well up to 10 million keys. I'd be unlikely to use it for over a thousand keys. - I don't mind what the...
by jeeswg
20 May 2019, 04:29
Forum: Ask For Help
Topic: How do you set just a Tab key, to trigger a text expansion?
Replies: 5
Views: 145

Re: How do you set just a Tab key, to trigger a text expansion?

There's also the * option: Hotstrings - Definition & Usage | AutoHotkey https://autohotkey.com/docs/Hotstrings.htm#Options * (asterisk): An ending character (e.g. Space, ., or Enter) is not required to trigger the hotstring. Two examples: :*:wt`t::What the...? :*:wt2`t:: ( what the heck is going on ...
by jeeswg
19 May 2019, 18:52
Forum: C/C++
Topic: C++: AHK source code: Base64Get/Base64Put and HexGet/HexPut
Replies: 1
Views: 111

C++: AHK source code: Base64Get/Base64Put and HexGet/HexPut

Here is some code for some potential Base64Get/Base64Put and HexGet/HexPut functions. They are based on StrGet/StrPut. ================================================== for AHK v1: function names and parameters: cf. StrGet(Address [, Length] [, Encoding := None]) HexGet(Address, Length, Case := "U"...
by jeeswg
19 May 2019, 18:49
Forum: C/C++
Topic: C++: AHK source code: StrJoin (alternating pad string)
Replies: 0
Views: 73

C++: AHK source code: StrJoin (alternating pad string)

Here is some code for a potential StrJoin function, that can accept an array of pad strings, for alternating pad strings. See also: code for potential StrCount/StrRept/StrJoin (constant pad string) functions: C++: AHK source code: potential functions - AutoHotkey Community https://autohotkey.com/boa...
by jeeswg
19 May 2019, 18:39
Forum: C/C++
Topic: C++: AHK source code: FloorMod
Replies: 0
Views: 65

C++: AHK source code: FloorMod

Here is some code for a potential FloorMod function. ================================================== for AHK v1: function names and parameters: [Mod] FloorMod(Dividend, Divisor) - note: BIF_Mod would be amended - note: it's generally more useful to have a Mod function always return a positive num...
by jeeswg
19 May 2019, 17:17
Forum: C/C++
Topic: C++: AHK source code: static/global variables
Replies: 0
Views: 65

C++: AHK source code: static/global variables

Is there a best way to create static/global variables, for individual/all functions, as would be done in AHK functions.

E.g. one idea: A_MSecLast [the milliseconds at the time you last retrieved A_Now/A_NowUTC]. Since concatenating A_Now/A_NowUTC and A_MSec is unreliable.
by jeeswg
19 May 2019, 12:39
Forum: Ask For Help
Topic: Find and replace in address bar
Replies: 4
Views: 131

Re: Find and replace in address bar

I've modified your script, it clears the clipboard before sending ctrl+x. I did this because ClipWait works by waiting until the clipboard text is non-blank. I've also made it use a temporary variable called 'text', to do the replacements on, instead of repeatedly using the Clipboard variable, which...
by jeeswg
18 May 2019, 11:33
Forum: Offtopic
Topic: Teens experience Windows 95
Replies: 6
Views: 592

Re: Teens experience Windows 95

Nice summary of the new (at the time) UI features: Start me up: Watch CNET's early coverage of Windows 95, back in 1995 - YouTube https://www.youtube.com/watch?v=Wu_gE8gQLIc [EDIT:] And a good summary for Windows 98. The Computer Chronicles - Windows 98 (1998) - YouTube https://www.youtube.com/watch...
by jeeswg
18 May 2019, 10:44
Forum: Offtopic
Topic: in what order to plug an external hard drive into a PC
Replies: 0
Views: 86

in what order to plug an external hard drive into a PC

Does it really matter what order you do it in? This link has a nice picture: 1, 2, 3, 4: How to physically connect, disconnect, and install a WD external / easystore drive on a Windows PC or Mac https://support-en.wd.com/app/answers/detail/a_id/12792 [PC]3[PC cable]4[drive]2[mains cable]1[mains] It ...
by jeeswg
17 May 2019, 14:55
Forum: Ask For Help
Topic: hopefully simple math formula
Replies: 2
Views: 121

Re: hopefully simple math formula

It's not too clear to me what you want, you could do a complete list of input/output values. Generally Mod, and Round can be useful. One idea is to divide, use Round, then multiply back again. In the example below, I just use Mod. q:: ;round to the nearest multiple of 3, and adjust Loop, 12 { vNum :...
by jeeswg
17 May 2019, 11:17
Forum: C/C++
Topic: C++: AHK source code: append number to array
Replies: 2
Views: 240

C++: AHK source code: append number to array

In the AHK v1 source code, this function would return an empty array: BIF_DECL(BIF_ReturnEmptyArray) { Object *output_array = Object::Create(); aResultToken.symbol = SYM_OBJECT; aResultToken.object = output_array; } What is the best way to append an Integer/Float to that array? Relevant functions: S...
by jeeswg
17 May 2019, 00:11
Forum: Forum Issues
Topic: get view count for current thread
Replies: 14
Views: 2484

Re: get view count for current thread

Each post has a search button, with placeholder (cue banner) text: 'Search this topic...'
Typing in a word from the OP (or another post), will find the thread, and show the view count.

Go to advanced search