Search found 3548 matches

by jeeswg
Today, 07:18
Forum: Ask For Help
Topic: Break text into new lines
Replies: 2
Views: 19

Re: Break text into new lines

Some ideas: q:: ;split text by '--', using RegExReplace vText := "--AAA-BBB--CCC-DDD--EEE-FFF" ;[^a] means not a, in RegEx, text between square brackets is a character class ;[^\-] means not -, - is escaped with \ because - has a special meaning within a character class e.g. [a-z] means al...
by jeeswg
Today, 01:54
Forum: Ask For Help
Topic: What are things that you can't do with AHK?
Replies: 5
Views: 78

Re: What are things that you can't do with AHK?

- It's possible that AHKHID might be able to help with distinguishing between key presses from different devices: NEW Barcode Input Capture (USB and RS232 compatible) - Page 2 - AutoHotkey Community https://autohotkey.com/boards/viewtopic.php?f=5&t=36241&p=170673#p170673 - To detect a clipbo...
by jeeswg
Today, 01:35
Forum: Bug Reports
Topic: How to find reason for crash every few weeks
Replies: 9
Views: 132

Re: How to find reason for crash every few weeks

- How do you know that it's crashing? Does the systray icon disappear? Does it no longer appear in Task Manager. Taken from: jeeswg's Explorer tutorial - AutoHotkey Community https://autohotkey.com/boards/viewtopic.php?f=7&t=31755 To show the Command Line column in Task Manager: if the Command L...
by jeeswg
Today, 01:16
Forum: Ask For Help
Topic: Firefox : toggle on/off sidebar - HELP
Replies: 1
Views: 32

Re: Firefox : toggle on/off sidebar - HELP

I was able to invoke the button using the Acc library. ;[Acc functions] ;Acc library (MSAA) and AccViewer download links - AutoHotkey Community ;https://autohotkey.com/boards/viewtopic.php?f=6&t=26201 q:: ;Mozilla Firefox - toggle show/hide Sidebars WinGet, hWnd, ID, A ;MsgBox, % Clipboard := JE...
by jeeswg
Today, 01:03
Forum: Ask For Help
Topic: Problem where Edit controls in a program are jumping around and trying to RegExMatch the correct ones
Replies: 3
Views: 58

Re: Problem where Edit controls in a program are jumping around and trying to RegExMatch the correct ones

- In reference to: oEdit[A_Index] := hCtl if !oEdit2.HasKey(vCtlX) ;it's possible that these 2 lines are unnecessary oEdit2[vCtlX] := [] ;it's possible that these 2 lines are unnecessary oEdit2[vCtlX, vCtlY] := hCtl vCount := A_Index - What I was doing here was: creating a key: oEdit[n], the nth Edi...
by jeeswg
Yesterday, 15:50
Forum: Ask For Help
Topic: Problem where Edit controls in a program are jumping around and trying to RegExMatch the correct ones
Replies: 3
Views: 58

Re: Problem where Edit controls in a program are jumping around and trying to RegExMatch the correct ones

- The key facts are: how many Edit controls are there, and are their physical positions (relative to the top-left corner) constant, or do they move about. - Here is some relevant code: q:: ;refer to Edit controls by their hWnd or by their coordinates WinGet, hWnd, ID, A oEdit := {}, oEdit2 := {} Loo...
by jeeswg
17 Feb 2018, 18:43
Forum: Ask For Help
Topic: 400 arrays of 400 values Topic is solved
Replies: 2
Views: 50

Re: 400 arrays of 400 values Topic is solved

Here are two ideas that I might consider. Cheers. q:: ;create array / list contents vText := " ;continuation section ( abcd efgh ijkl mnop )" ;create array oArray := StrSplit(vText, "`n") ;list an example MsgBox, % SubStr(oArray[3], 3, 1) ;list contents vOutput := "" fo...
by jeeswg
17 Feb 2018, 17:59
Forum: AutoHotkey v2 Development
Topic: list of every object type/property/method
Replies: 13
Views: 295

Re: list of every object type/property/method

- @lexikos: Many thanks for your detailed response. - I read the documentation and thought: there are exactly 3 meta-functions, they are called when keys/methods aren't found. But your explanation makes a lot of sense. Also, declining grammar standards in schools might lead people (e.g. me) to miss ...
by jeeswg
17 Feb 2018, 16:55
Forum: Ask For Help
Topic: HSB to HEX Topic is solved
Replies: 14
Views: 124

Re: HSB to HEX Topic is solved

- These calculations gave the same result as Photoshop, although, I just computed the numbers, I can't vouch for their accuracy. Multiplying by 255 didn't quite give the right answers, although multiplying by 256 did. - I'd been meaning to look at HSV at some point, so thanks for the reminder. - The...
by jeeswg
17 Feb 2018, 16:09
Forum: Ask For Help
Topic: Please help on RegExMatch
Replies: 3
Views: 64

Re: Please help on RegExMatch

Note: RegExMatch has a case-insensitive option: i.

Regular Expressions (RegEx) - Quick Reference
https://autohotkey.com/docs/misc/RegEx-QuickRef.htm#Options
by jeeswg
17 Feb 2018, 16:05
Forum: Ask For Help
Topic: HSB to HEX Topic is solved
Replies: 14
Views: 124

Re: HSB to HEX Topic is solved

Might come in handy at some point.

Code: [Select all]GeSHi © Codebox Plus

q:: ;dec2hex / hex2dec
;dec2hex
vNum := 255
MsgBox, % Format("0x{:X}", vNum)

;hex2dec
vHex := 0xFF
MsgBox, % vHex+0
return
by jeeswg
17 Feb 2018, 11:25
Forum: Ask For Help
Topic: Can't activate Windows Explorer window
Replies: 3
Views: 47

Re: Can't activate Windows Explorer window

The usual things would be to: try Window Spy to get identifying information for the window, and consider if the issue is admin windows, and to add MsgBox/SoundBeep to your hotkey subroutine to check that it's working.
by jeeswg
17 Feb 2018, 10:54
Forum: Ask For Help
Topic: Can't activate Windows Explorer window
Replies: 3
Views: 47

Re: Can't activate Windows Explorer window

Perhaps this:

Code: [Select all]GeSHi © Codebox Plus

q:: ;activate Explorer window
if WinExist("ahk_class CabinetWClass") || WinExist("ahk_class ExploreWClass")
WinActivate
return
by jeeswg
17 Feb 2018, 07:25
Forum: Tutorials
Topic: jeeswg's benchmark tests
Replies: 51
Views: 1789

Re: jeeswg's benchmark tests

Here's an interesting one, object count keys: clone+delete v. for loop v. delete. See results at the bottom. Cheers. q:: ;object count keys: clone+delete v. for loop v. delete oQPC := [] ;MsgBox, % A_BatchLines FileRead, vText, % A_ScriptFullPath obj := {} vIndex := 0 Loop, 100 ;Loop, 10 Loop, Parse...
by jeeswg
16 Feb 2018, 20:52
Forum: Ask For Help
Topic: Difference between = and == Topic is solved
Replies: 4
Views: 104

Re: Difference between = and == Topic is solved

I realised an important counterintuitive distinction between !(a = b) and (a != b), they are not equivalent: q:: ;the difference between: ;!(a = b) ;(a != b) StringCaseSense, On MsgBox, % !("A" = "A") ;0 ;= is case insensitive MsgBox, % !("A" = "a") ;0 ;= is c...
by jeeswg
16 Feb 2018, 17:55
Forum: AutoHotkey v2 Development
Topic: A_ variables
Replies: 18
Views: 796

Re: A_ variables

- Yes, I was thinking that the ByRef issue would need resolving, or having a separate 'set setting' function just for 'A_' variables. - Yes, I was thinking that (Set)KeyDelay and (Set)KeyDelayPlay would be better than what we have currently, nice to see that it was part of your package. - Haha 'An e...
by jeeswg
16 Feb 2018, 16:56
Forum: Ask For Help
Topic: Access Parent Instance Variables from a Nested Class
Replies: 4
Views: 110

Re: Access Parent Instance Variables from a Nested Class

Some ideas. Based on the example by Helgef here: object classes: redefine __Set() temporarily / general queries - AutoHotkey Community https://autohotkey.com/boards/viewtopic.php?f=5&t=42674&p=193947#p193947 q:: obj := ClassName.NestedClass.Method() obj := new ClassName.NestedClass obj.Metho...
by jeeswg
16 Feb 2018, 14:57
Forum: AutoHotkey v2 Development
Topic: A_ variables
Replies: 18
Views: 796

Re: A_ variables

- Your point about getting/setting in one go, is a good one, however, I would suggest instead, a generalised Assign function: vRV := A_RegView, A_RegView := 64 vDHW := A_DetectHiddenWindows, A_DetectHiddenWindows := 1 vOldValue := Assign(vMyVar, vNewValue) oOldValues := Assign(vMyVar1, vMyVar2, vNew...
by jeeswg
15 Feb 2018, 18:25
Forum: Ask For Help
Topic: Excel_Get is AMAZING, could someone make a PowerPoint_Get?
Replies: 3
Views: 84

Re: Excel_Get is AMAZING, could someone make a PowerPoint_Get?

- I hadn't done anything with COM and PowerPoint before today, but thanks to some example code by HotKeyIt (link lower down), I managed to get a basic example together. - I've created a PowerPoint_Get function (based on kon's Excel_Get update function) below, it appears to work for me, so hopefully ...

Go to advanced search