Search found 4508 matches

by jeeswg
Yesterday, 17:02
Forum: Ask For Help
Topic: How to fill and read an array Topic is solved
Replies: 5
Views: 62

Re: How to fill and read an array Topic is solved

To handle CRLF-delimited or LF-delimited text:

Code: [Select all]GeSHi © Codebox Plus

Lines := StrSplit(str, "`n", "`r")
by jeeswg
Yesterday, 11:37
Forum: Ask For Help
Topic: Prevent/disable text selection in Edit control?
Replies: 9
Views: 97

Re: Prevent/disable text selection in Edit control?

- If you use a Static control ('Text' control in AHK), is that sufficient? - Could you explain exactly what you want to achieve? - Or do you want the caret to appear, and to be able to navigate through the control via caret/scrollbars? - You could monitor WM_KEYDOWN (check for shift down and return ...
by jeeswg
21 Jun 2018, 17:27
Forum: Ask For Help
Topic: RegExReplace Transpose Chords
Replies: 27
Views: 459

Re: RegExReplace Transpose Chords

- Interesting. Btw do # or b (case sensitive) ever appear in the text (chord) but not as part of notes. - In the function definition, you can specify oArray2, to allow you to use the flats instead of the sharps: ChordTranspose(vText, vST1:="", vST2:="", vST3:="", vST4:=...
by jeeswg
21 Jun 2018, 17:24
Forum: Ask For Help
Topic: Taskbar shows after GUI is closed
Replies: 3
Views: 89

Re: Taskbar shows after GUI is closed

So that would be AHK v1.1.29.01. I would try to see if you can get the error with older versions. And I would try to do various bits of script simplification to try to narrow down the cause (which I appreciate can be fiddly).
by jeeswg
21 Jun 2018, 02:29
Forum: Ask For Help
Topic: RegExReplace Transpose Chords
Replies: 27
Views: 459

Re: RegExReplace Transpose Chords

- You can pass a note array as one of the parameters in the function. oArray := StrSplit("C,C#,D,D#,E,F,F#,G,G#,A,A#,B", ",") oArray := StrSplit("C,Db,D,Eb,E,F,Gb,G,Ab,A,Bb,B", ",") - I could improve the function to handle both types of notes as the *source* (...
by jeeswg
20 Jun 2018, 18:39
Forum: Ask For Help
Topic: RegExReplace Transpose Chords
Replies: 27
Views: 459

Re: RegExReplace Transpose Chords

- I've edited the original function (in a previous post) by adding these 2 lines: if !vST continue - The reason I missed this relates to the fact that you can't do !(vST is "number") in AHK v1 (yet?). I got distracted by this, so didn't handle the case where the number could be 0. ...
by jeeswg
20 Jun 2018, 16:52
Forum: Ask For Help
Topic: RegExReplace Transpose Chords
Replies: 27
Views: 459

Re: RegExReplace Transpose Chords

This is pretty much what's needed, I've only tested it on a simple chord: q:: ;test transpose chords vText := "A/B,C/D" MsgBox, % ChordTranspose(vText, 1, 1, 1, 1) ;A#/C,C#/D# MsgBox, % ChordTranspose(vText, 2, 2, 2, 2) ;B/C#,D/E MsgBox, % ChordTranspose(vText, -1, -1, -1, -1) ;G#/A#,B/C# ...
by jeeswg
20 Jun 2018, 16:20
Forum: Ask For Help
Topic: RegExReplace Transpose Chords
Replies: 27
Views: 459

Re: RegExReplace Transpose Chords

- Thanks for your response, AFAIK you have everything you need. So perhaps, one example of something you're trying to do but haven't managed to do yet. - I'll see about creating those 4 functions, btw RegExMatch will need to be involved to identify the note to replaced. - Btw will the text to be rep...
by jeeswg
20 Jun 2018, 14:50
Forum: Ask For Help
Topic: Taskbar shows after GUI is closed
Replies: 3
Views: 89

Re: Taskbar shows after GUI is closed

Could you say which OS and version of AHK you are using, thanks.
by jeeswg
20 Jun 2018, 14:47
Forum: Ask For Help
Topic: Hold down key and modifier Topic is solved
Replies: 2
Views: 31

Re: Hold down key and modifier Topic is solved

Perhaps:

Code: [Select all]GeSHi © Codebox Plus

SendInput, {Text}X ;requires AHK v1.1.27+
by jeeswg
20 Jun 2018, 08:58
Forum: Ask For Help
Topic: Help! How to use make the mouse scroll through a specified window
Replies: 5
Views: 48

Re: Help! How to use make the mouse scroll through a specified window

To make it loop you can use Loop and Sleep, otherwise I'm not sure.
by jeeswg
20 Jun 2018, 08:21
Forum: Ask For Help
Topic: Help! How to use make the mouse scroll through a specified window
Replies: 5
Views: 48

Re: Help! How to use make the mouse scroll through a specified window

Perhaps something like this. Adjust the numbers as necessary. q:: ;internet explorer - WheelDown via WM_MOUSEWHEEL WinGet, hWnd, ID, ahk_class IEFrame ControlGetFocus, vCtlClassNN, % "ahk_id " hWnd ControlGet, hCtl, Hwnd,, % vCtlClassNN, % "ahk_id " hWnd vNum := -60 ;negative mea...
by jeeswg
20 Jun 2018, 07:37
Forum: Ask For Help
Topic: Help! How to use make the mouse scroll through a specified window
Replies: 5
Views: 48

Re: Help! How to use make the mouse scroll through a specified window

This works for me for a pdf opened in Internet Explorer:

Code: [Select all]GeSHi © Codebox Plus

q:: ;internet explorer - WheelDown
WinActivate, ahk_class IEFrame
SendInput, {WheelDown}
return
by jeeswg
20 Jun 2018, 07:32
Forum: Ask For Help
Topic: How to select a Class NN control Topic is solved
Replies: 5
Views: 70

Re: How to select a Class NN control Topic is solved

Possibly it would help to do ControlFocus prior to Click/MouseClick/ControlClick.
by jeeswg
20 Jun 2018, 07:25
Forum: Ask For Help
Topic: Scrollbars for Gui object, AHK V2
Replies: 4
Views: 86

Re: Scrollbars for Gui object, AHK V2

- These work for me: ;AHK v2 #SingleInstance force oGui := GuiCreate(, "MyWinTitle") oGui.OnEvent("Close", "Gui_Close") hGui := oGui.hWnd oGui.Add("Edit", "+Multi +HScroll +VScroll", "EDIT 1") oGui.Add("Edit", "r10 +HScroll +...
by jeeswg
20 Jun 2018, 04:54
Forum: Ask For Help
Topic: RegExReplace Transpose Chords
Replies: 27
Views: 459

Re: RegExReplace Transpose Chords

I'm not really sure what you're asking. You could give some input/output examples.
by jeeswg
19 Jun 2018, 18:11
Forum: Ask For Help
Topic: Scrollbars for Gui object, AHK V2
Replies: 4
Views: 86

Re: Scrollbars for Gui object, AHK V2

- Here are 2 examples. - The scrollbars appear greyed out until you type enough text horizontally/vertically. ;AHK v2 #SingleInstance force oGui := GuiCreate(, "MyWinTitle") oGui.OnEvent("Close", "Gui_Close") hGui := oGui.hWnd oGui.Add("Edit", "w100 h100 ...
by jeeswg
19 Jun 2018, 17:48
Forum: Ask For Help
Topic: Splitting a string into multiple lines with a maximum lenght Topic is solved
Replies: 14
Views: 231

Re: Splitting a string into multiple lines with a maximum lenght Topic is solved

I did something like this here, it uses InStr to find the first occurrence of a string before the nth character. To search backwards you have to convert the character index to a negative (or zero) index that InStr can handle. Edit some text files, string length - AutoHotkey Community https://autohot...
by jeeswg
19 Jun 2018, 17:33
Forum: Ask For Help
Topic: Script to Find Repeating Words
Replies: 9
Views: 151

Re: Script to Find Repeating Words

- Here's an attempt. It's essentially just a parsing loop using space as the delimiter. You then have to consider how to deal with any non-letters. I have considered commas and full stops in the example below. - If you want to know the exact position of where the repeated match occurs, you could use...
by jeeswg
19 Jun 2018, 11:33
Forum: Ask For Help
Topic: click a control inside of a listbox
Replies: 4
Views: 75

Re: click a control inside of a listbox

Can you not set the selected item and then use ControlSend/SendInput with {Enter}?

Go to advanced search