Search found 5152 matches

by jeeswg
Yesterday, 21:45
Forum: Ask For Help
Topic: case-insensitive searching in binary buffers
Replies: 0
Views: 26

case-insensitive searching in binary buffers

tl;dr I can do it, but I'm interested in ideas for the algorithm - I've been interested in having a function for case-insensitive searching in binary buffers. E.g. search a binary file for a string. - AFAIK there are no existing Winapi functions for searching for ANSI/UTF-8/UTF-16 strings, which can...
by jeeswg
Yesterday, 20:09
Forum: Ask For Help
Topic: Is there a means of validating a ControlSetText command?
Replies: 5
Views: 79

Re: Is there a means of validating a ControlSetText command?

I've never had any problems with ControlSetText, so I'm wondering if this is really the solution to your problem, however, here's a custom function. q:: ControlGetText, vText, Edit1, A if (vText = "") MsgBox, % MyControlSetText("abc", "Edit1", "A") return MyControlSetText(vText, vControl:="", vWinTi...
by jeeswg
Yesterday, 19:30
Forum: Ask For Help
Topic: escape characters issue
Replies: 0
Views: 18

escape characters issue

Generally it appears that text is read from left to right, and so: ``t is interpreted as `` then t and so appears literally as `t ``, is interpreted as `` then , and so appears literally as `, However semicolon appears to be an exception: ``; appears literally as ; I did not see any mention of this ...
by jeeswg
Yesterday, 13:36
Forum: Ask For Help
Topic: 2nd Clipboard Topic is solved
Replies: 1
Views: 25

Re: 2nd Clipboard Topic is solved

Try this. Ctrl+Win+Num to store text (and restore the clipboard). Ctrl+Num to paste text (and restore the clipboard). Cheers. ^#1:: ;store selected text as variable ^#2:: ^#3:: ^#4:: ^#5:: vNum := SubStr(A_ThisHotkey, StrLen(A_ThisHotkey)) ClipSaved := ClipboardAll Clipboard := "" SendInput, ^c Clip...
by jeeswg
Yesterday, 09:49
Forum: Ask For Help
Topic: Include files using variables
Replies: 2
Views: 39

Re: Include files using variables

Using information from the link above, try this:

Code: Select all

#Include \\10.1.1.111\AutoHotKeyScripts ;change #Include's working dir
#Include someScript.ahk ;include file from #Include's working dir
by jeeswg
Yesterday, 08:49
Forum: Wish List
Topic: [Forum] Public edit history
Replies: 7
Views: 103

Re: [Forum] Public edit history

- One disadvantage is that if you edit a big post 100 times, that post would have to be stored 100 times. - Another disadvantage is that instead of being able to remove things yourself (e.g. accidentally including an email address), you have to ask mods/admins to assist you, and worse still, that ca...
by jeeswg
19 Oct 2018, 22:21
Forum: Ask For Help
Topic: Capture OutputDebugString
Replies: 6
Views: 190

Re: Capture OutputDebugString

Try the script here. Cheers.
retrieve OutputDebug text - AutoHotkey Community
https://autohotkey.com/boards/viewtopic ... 76&t=58069
by jeeswg
19 Oct 2018, 22:14
Forum: Ask For Help
Topic: retrieve OutputDebug text
Replies: 0
Views: 46

retrieve OutputDebug text

tl;dr help improve my mostly-finished script that receives OutputDebug (OutputDebugString) text - I've been using #Warn in my scripts, and adding 'local' etc, to make my functions as usable as possible for other people. - A MsgBox for each of #Warn's warning is too unwieldy. #Warn's OutputDebug opti...
by jeeswg
19 Oct 2018, 19:39
Forum: Ask For Help
Topic: Is there a means of validating a ControlSetText command?
Replies: 5
Views: 79

Re: Is there a means of validating a ControlSetText command?

I would just use ControlGetText to check, or create a custom ControlSetText function that used ControlGetText to check.
by jeeswg
19 Oct 2018, 17:07
Forum: Ask For Help
Topic: compiled scripts versus regular scripts
Replies: 0
Views: 51

compiled scripts versus regular scripts

- With regard to tutorials and AHK v2 development, I'm interested in any differences between regular scripts and compiled scripts. - E.g. any tips re. what differences you need to be aware of when writing a script that you know is going to be compiled. Thanks. - Some differences: - A_IsCompiled is s...
by jeeswg
19 Oct 2018, 11:39
Forum: Ask For Help
Topic: Is there a means of validating a ControlSetText command?
Replies: 5
Views: 79

Re: Is there a means of validating a ControlSetText command?

Code: Select all

;before:
While (WinExist("Child Window") && If (bState="")) {
While,(WinExist("Child Window") && (bState<>"%cCommand%%vValue%")) {

;after:
while (WinExist("Child Window") && (bState="")) {
while (WinExist("Child Window") && (bState<>cCommand vValue)) {
Cheers.
by jeeswg
19 Oct 2018, 08:46
Forum: Ask For Help
Topic: iniRead UTF-8
Replies: 16
Views: 218

Re: iniRead UTF-8

- Here is some code that works out how many bytes each Unicode character requires in each system. - It appears that for characters above 65535 in both UTF-8 and UTF-16, 4 bytes are required. - @SOTE: The point I made was that if you want to store Latin-based text, using UTF-8 will generally take up ...
by jeeswg
18 Oct 2018, 17:34
Forum: AutoHotkey v2 Development
Topic: Operators vs Methods
Replies: 35
Views: 457

Re: Operators vs Methods

@iseahound: If higher level concepts have influenced your AutoHotkey v2 Development ideas, what about lower level concepts? Assembly language etc. Cheers.
by jeeswg
18 Oct 2018, 12:45
Forum: Ask For Help
Topic: WinActivate / WinWaitActive don't work Topic is solved
Replies: 3
Views: 45

Re: WinActivate / WinWaitActive don't work Topic is solved

Code: Select all

;these work:
WinActivate, % "ahk_exe notepad.exe"
WinWaitActive, % "ahk_exe notepad.exe",, 5

;these work also:
WinActivate, ahk_exe notepad.exe
WinWaitActive, ahk_exe notepad.exe,, 5
Cheers.
by jeeswg
18 Oct 2018, 12:35
Forum: Ask For Help
Topic: Is ^!7 a valid hotkey?
Replies: 3
Views: 57

Re: Is ^!7 a valid hotkey?

Continuing on from what eelrod said:

Code: Select all

^!7::
^!Numpad7:: ;works when NumLock is on
^!NumpadHome:: ;works when NumLock is off
MsgBox, % A_ThisHotkey
return
by jeeswg
18 Oct 2018, 12:11
Forum: Ask For Help
Topic: Send text to non-focus Notepad in one chunk
Replies: 6
Views: 45

Re: Send text to non-focus Notepad in one chunk

- Consider using EditPaste, it will immediately insert text into Notepad. Although, note: when you use EditPaste, just like when you send key presses, if any text is selected, it will be overwritten.
- EditPaste works on Edit controls.

Code: Select all

q::
Control, EditPaste, abc, Edit1, A
return
by jeeswg
17 Oct 2018, 20:22
Forum: Ask For Help
Topic: Set Highlight of selected text
Replies: 1
Views: 37

Re: Set Highlight of selected text

For highlighting, something like this: F10:: ComObjActive("Word.Application").Selection.Range.HighlightColorIndex := 2 F11:: ComObjActive("Word.Application").Selection.Range.HighlightColorIndex := 3 F12:: ComObjActive("Word.Application").Selection.Range.HighlightColorIndex := 4 Possibly, to turn off...
by jeeswg
17 Oct 2018, 18:44
Forum: Ask For Help
Topic: convert bytes to shorts (by converting ANSI to Unicode)
Replies: 0
Views: 34

convert bytes to shorts (by converting ANSI to Unicode)

- I'm interested in converting bytes to shorts. I.e. each byte becomes 2 bytes, e.g. 'AA' becomes 'AA00', you double the amount of data. - I have found that MultiByteToWideChar can do this (demonstrated below), I wondered if there were any other well-known ways. (That is my 'Ask For Help' question.)...
by jeeswg
17 Oct 2018, 13:56
Forum: Ask For Help
Topic: How to determine if Word is open?
Replies: 2
Views: 52

Re: How to determine if Word is open?

- Two ideas are:
- if WinExist("ahk_class OpusApp") ;MS Word
- A try/catch block:
Try - Syntax & Usage | AutoHotkey
https://autohotkey.com/docs/commands/Try.htm
by jeeswg
17 Oct 2018, 13:12
Forum: Ask For Help
Topic: Extending array/object functionality?
Replies: 1
Views: 47

Re: Extending array/object functionality?

Perhaps you could write your own StrSplit function, using a parsing a loop to parse the text, and a custom class with the extended functionality.

Go to advanced search