Search found 4492 matches

by jeeswg
23 minutes ago
Forum: Ask For Help
Topic: Scrollbars for Gui object, AHK V2
Replies: 1
Views: 21

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
46 minutes ago
Forum: Ask For Help
Topic: Splitting a string into multiple lines with a maximum lenght
Replies: 4
Views: 72

Re: Splitting a string into multiple lines with a maximum lenght

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
Today, 17:33
Forum: Ask For Help
Topic: Script to Find Repeating Words
Replies: 5
Views: 43

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
Today, 11:33
Forum: Ask For Help
Topic: click a control inside of a listbox
Replies: 4
Views: 53

Re: click a control inside of a listbox

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

Re: File append in specific line (Possible?)

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

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
Yesterday, 19:55
Forum: Ask For Help
Topic: store treevalues into array?
Replies: 1
Views: 33

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
Yesterday, 17:05
Forum: Ask For Help
Topic: Automatically log into an application
Replies: 1
Views: 27

Re: Automatically log into an application

- 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+.
by jeeswg
Yesterday, 16:08
Forum: Ask For Help
Topic: Using IE.Document.GetElementsByClassname
Replies: 10
Views: 1758

Re: Using IE.Document.GetElementsByClassname

You can try IE=edge as was mentioned, but also IE=9:
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta http-equiv="X-UA-Compatible" content="IE=9">
by jeeswg
Yesterday, 11:26
Forum: Bug Reports
Topic: VA problem in 1.1.29.00
Replies: 8
Views: 121

Re: VA problem in 1.1.29.00

So what has changed in AHK? Is it stricter error handling correctly identifying an error? (When SetMute is used via DllCall with too few parameters.) The quote below perhaps suggests this but doesn't state it explicitly. Changes & New Features https://autohotkey.com/docs/AHKL_ChangeLog.htm#v1.1....
by jeeswg
Yesterday, 09:22
Forum: Bug Reports
Topic: VA problem in 1.1.29.00
Replies: 8
Views: 121

Re: VA problem in 1.1.29.00

Did you test v1.1.29.01?
by jeeswg
Yesterday, 05:57
Forum: Ask For Help
Topic: RegExReplace Transpose Chords
Replies: 13
Views: 174

Re: RegExReplace Transpose Chords

These examples seem to be right or mostly right: q:: ;RegExReplace - chords vText := " (Join`r`n 1 ^1 ^^1 1/2 1/2,3 1/2,3/4 1/2,^3/4 1/2,^^3/4 1,^^3/4 1,^3/4 ^1/2,^^3/4 ^^1/2,^^3/4 ^1,^^3/4 ^^1,^^3/4 ,3 ,3/4 ,^3 ,^^3 ,^^3/4 ,^3/4 )" vText1 := RegExReplace(vText, "m)^\^*\K\d", &qu...
by jeeswg
Yesterday, 05:30
Forum: Wish List
Topic: Suggestions on documentation improvements
Replies: 411
Views: 69942

Re: Suggestions on documentation improvements

@hoppfrosch: Which version of AHK v2 are you using? I tried FileCreateDir as a command and function in AHK v2.0-a096 and got the same error as Helgef.
by jeeswg
17 Jun 2018, 20:16
Forum: Ask For Help
Topic: RegExReplace Transpose Chords
Replies: 13
Views: 174

Re: RegExReplace Transpose Chords

I thought I should mention this, which could be useful at some point:

Code: [Select all]GeSHi © Codebox Plus

[A-G][b#]?

A capital letter between A and G, optionally followed by b or #. The question mark means 0 or 1 of the previous character.
by jeeswg
17 Jun 2018, 19:14
Forum: Ask For Help
Topic: How to Click a Button in a Web Page?
Replies: 2
Views: 58

Re: How to Click a Button in a Web Page?

- Here's the sort of investigation/experimentation I do, to identify the right web element in Internet Explorer: ;WBGet function - AutoHotkey Community ;https://autohotkey.com/boards/viewtopic.php?f=6&t=39869 ;note: getElementsByClassName/getElementsByTagName methods [elements plural]: ;you can ...
by jeeswg
17 Jun 2018, 18:33
Forum: Ask For Help
Topic: RegExReplace Transpose Chords
Replies: 13
Views: 174

Re: RegExReplace Transpose Chords

- Something like this might help to replace the nth occurrence: q:: ;RegEx - replace specific strings vText := "X/X,X/X" vOutput := "" vOutput .= RegExReplace(vText, "X(?=.*X.*X.*X)", "x") "`r`n" vOutput .= RegExReplace(vText, ".*\KX(?=.*X.*X)&q...
by jeeswg
17 Jun 2018, 18:03
Forum: Ask For Help
Topic: RegExReplace Transpose Chords
Replies: 13
Views: 174

Re: RegExReplace Transpose Chords

Probably these: ;note: ^ indicates starts with ;note: [^a] means not a ;note: \^ indicates ^ (it needs to be escaped with a backslash to use it literally, instead of for a special purpose) ;note: \K can also be used (?<=^\^) ;starts with ^ (?<=^\^\^) ;starts with ^^ (?<=\^\^) ;preceded by ^^ (?<=[^^...
by jeeswg
17 Jun 2018, 16:59
Forum: Ask For Help
Topic: RegExReplace Transpose Chords
Replies: 13
Views: 174

Re: RegExReplace Transpose Chords

This will probably cover most of the issues: ;uses: ^ $ [start/end] ;uses: \K ;uses: (?<=) (?<!) (?=) (?!) [positive/negative look-behind/look-ahead assertions] q:: ;RegEx - replace specific strings vText := "X/X,X/X" vOutput := "" vOutput .= RegExReplace(vText, "^X", &...
by jeeswg
17 Jun 2018, 15:54
Forum: Ask For Help
Topic: RegExReplace Transpose Chords
Replies: 13
Views: 174

Re: RegExReplace Transpose Chords

- I would suggest showing a list/lists of the form: abc -> def. That way more people will be quicker to help. Cheers.
- You might also list everything that X could be (list/lists).
by jeeswg
17 Jun 2018, 15:16
Forum: Ask For Help
Topic: Capitalize first paragraph letter (not just after .?!)
Replies: 13
Views: 130

Re: Capitalize first paragraph letter (not just after .?!)

Add this to your original code perhaps.

Go to advanced search