Search found 4504 matches

by jeeswg
Today, 02:29
Forum: Ask For Help
Topic: RegExReplace Transpose Chords
Replies: 25
Views: 386

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
Yesterday, 18:39
Forum: Ask For Help
Topic: RegExReplace Transpose Chords
Replies: 25
Views: 386

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
Yesterday, 16:52
Forum: Ask For Help
Topic: RegExReplace Transpose Chords
Replies: 25
Views: 386

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
Yesterday, 16:20
Forum: Ask For Help
Topic: RegExReplace Transpose Chords
Replies: 25
Views: 386

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
Yesterday, 14:50
Forum: Ask For Help
Topic: Taskbar shows after GUI is closed
Replies: 2
Views: 50

Re: Taskbar shows after GUI is closed

Could you say which OS and version of AHK you are using, thanks.
by jeeswg
Yesterday, 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
Yesterday, 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
Yesterday, 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
Yesterday, 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
Yesterday, 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
Yesterday, 07:25
Forum: Ask For Help
Topic: Scrollbars for Gui object, AHK V2
Replies: 4
Views: 81

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
Yesterday, 04:54
Forum: Ask For Help
Topic: RegExReplace Transpose Chords
Replies: 25
Views: 386

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: 81

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: 146

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: 74

Re: click a control inside of a listbox

Can you not set the selected item and then use ControlSend/SendInput with {Enter}?
by jeeswg
19 Jun 2018, 11:29
Forum: Ask For Help
Topic: File append in specific line (Possible?)
Replies: 6
Views: 119

Re: File append in specific line (Possible?)

With InStr you can get the nth occurrence of a string.
by jeeswg
19 Jun 2018, 07:38
Forum: Ask For Help
Topic: carriage return wont work
Replies: 4
Views: 53

Re: carriage return wont work

To have line breaks work properly when a text file is opened in Notepad, and when the contents of Edit controls are set, use CRLFs not LFs.

Code: [Select all]GeSHi © Codebox Plus

vText := StrReplace(vText, "`n", "`r`n")
by jeeswg
18 Jun 2018, 19:55
Forum: Ask For Help
Topic: store treevalues into array?
Replies: 1
Views: 45

Re: store treevalues into array?

Probably something like this: q:: ;CRLF-delimited list to linear array vText := "a`r`nb`r`nc" oArray := StrSplit(vText, "`r`n") vOutput := "" for vKey, vValue in oArray vOutput .= vKey " " vValue "`r`n" MsgBox, % vOutput return
by jeeswg
18 Jun 2018, 17:05
Forum: Ask For Help
Topic: Automatically log into an application Topic is solved
Replies: 1
Views: 33

Re: Automatically log into an application Topic is solved

- Try sending it to Notepad to see if it has sent correctly.
- Special characters not being escaped, and capitalisation could be problems.
- Try Send, {Text}password. To avoid text being capitalised incorrectly. The {Text} option is available on AHK v1.1.27+.

Go to advanced search