Search found 1161 matches

by Descolada
18 minutes ago
Forum: Scripts and Functions (v2)
Topic: [alpha] WinEvent - easily detect window open, close, move, and more
Replies: 32
Views: 1901

Re: [alpha] WinEvent - easily detect window open, close, move, and more

Archimede no. If you use WinEvent.Pause(0) then only events that aren't paused will restart. If Event1 is active and Event2 is paused, then after using WinEvent.Pause(1) no events will be active, and after WinEvent.Pause(0) only Event1 will be active. If you also pause Event1 while WinEvent is paus...
by Descolada
23 minutes ago
Forum: Scripts and Functions (v2)
Topic: UIA v2
Replies: 375
Views: 54270

Re: UIA v2

@songdg no there isn't such a method, and I won't add it either because it is outside the scope of this library. There are other libraries capable of doing that :)
by Descolada
Today, 12:10
Forum: Scripts and Functions (v2)
Topic: [alpha] WinEvent - easily detect window open, close, move, and more
Replies: 32
Views: 1901

Re: [alpha] WinEvent - easily detect window open, close, move, and more

Archimede that behavior is actually by design, although I'm not 100% sure it should be. oHook.IsPaused tells you whether that event hook is paused or will still be paused if WinEvent itself is reactivated. Lets say you have two event hooks Event1 and Event2, and Event2 is paused. You now call WinEv...
by Descolada
Today, 11:47
Forum: Scripts and Functions (v2)
Topic: [alpha] WinEvent - easily detect window open, close, move, and more
Replies: 32
Views: 1901

Re: [alpha] WinEvent - easily detect window open, close, move, and more

Archimede it has no return value, it just stops monitoring for the event. There are multiple ways of doing that: npHook := WinEvent.Show(NotepadCreated, "ahk_exe notepad.exe") npHook.Stop() ; you can use the returned object WinEvent.Stop("Show", "ahk_exe notepad.exe") ; or stop it using the WinTitl...
by Descolada
Today, 06:18
Forum: Scripts and Functions (v2)
Topic: [alpha] WinEvent - easily detect window open, close, move, and more
Replies: 32
Views: 1901

Re: [alpha] WinEvent - easily detect window open, close, move, and more

- to set the function call and, into the called function, filter the window name is simple, but requires many execution time; I tried to write WinEvent to account for that and it shouldn't require more execution time than normal. - to set only window ( eg, no menu or other ) to call the function ( ...
by Descolada
Today, 04:57
Forum: Scripts and Functions (v2)
Topic: [alpha] WinEvent - easily detect window open, close, move, and more
Replies: 32
Views: 1901

Re: [alpha] WinEvent - easily detect window open, close, move, and more

@Archimede what exactly is missing? Currently WinEvent supports the same window criteria as the native window functions (eg WinExist), so you can filter those windows out by using WinTitle criteria.
by Descolada
11 May 2024, 13:22
Forum: Scripts and Functions (v2)
Topic: [alpha] WinEvent - easily detect window open, close, move, and more
Replies: 32
Views: 1901

Re: [alpha] WinEvent - easily detect window open, close, move, and more

@Archimede thanks for the feedback, that should be fixed now :)
by Descolada
08 May 2024, 14:56
Forum: Ask for Help (v2)
Topic: UIA Viewer Issues
Replies: 1
Views: 130

Re: UIA Viewer Issues

avedium Have you tried MenuSelect instead of UIA though? The code would be something like this: MenuSelect("Aloha Configuration Center : Quality Dining Burger King ahk_exe AeMShell.exe", , "Reports", "Aloha Configuration Center", "Data Distribution") As for the UIA approach... Notice in UIAViewer t...
by Descolada
08 May 2024, 10:15
Forum: Scripts and Functions (v2)
Topic: UIA v2
Replies: 375
Views: 54270

Re: UIA v2

reddyshyam please post concrete example code and the website address which I could test (and which fails) in Brave browser, because as I've shown what you are doing should work, and if it isn't then probably something unknown is going on. roeleboele that is exactly how you can use variables in the ...
by Descolada
07 May 2024, 00:12
Forum: Scripts and Functions (v2)
Topic: UIA v2
Replies: 375
Views: 54270

Re: UIA v2

Anyone know why I'd be getting an error message with this? #include .\Lib\UIA.ahk #include .\Lib\UIA_Browser.ahk #0:: { cUIA := UIA_Browser(wTitle="A") ;obviously more code here } Warning: This variable appears to never be assigned a value. Specifically: local wTitle 031: } 037: { ▶ 038: cUIA := UI...
by Descolada
06 May 2024, 12:17
Forum: Scripts and Functions (v2)
Topic: UIA v2
Replies: 375
Views: 54270

Re: UIA v2

reddyshyam can you post example code that replicates the problem? The following worked on this page just as expected: #include UIA.ahk chromeEl := UIA.ElementFromHandle("UIA v2 - Page 19 - AutoHotkey Community - Google Chrome ahk_exe chrome.exe") chromeEl.FindElement({Type:"Edit", Name:"Subject", m...
by Descolada
06 May 2024, 11:27
Forum: Scripts and Functions (v2)
Topic: [alpha] WinEvent - easily detect window open, close, move, and more
Replies: 32
Views: 1901

Re: [alpha] WinEvent - easily detect window open, close, move, and more

shipaddicted your example code didn't work because I hadn't accounted for the window title to change: so far WinEvent.Active was only activated when the foreground window changed, not when the title changed (eg when switching tabs in Chrome). This should be fixed now. I don't think you can get an i...
by Descolada
06 May 2024, 08:03
Forum: Wish List
Topic: Notify if not UTF-8? -- [Update: Not possible, me thinks]
Replies: 15
Views: 1076

Re: Notify if not UTF-8? -- [Update: Not possible, me thinks]

A directive which is encoded as...? The program has already decided on an encoding and begun reading the file. The directive is encoded as whatever the user decided or accidentally used... Practically all encodings share the ASCII character set, which is what most of AHK syntax uses, so AHK may loa...
by Descolada
06 May 2024, 05:31
Forum: Wish List
Topic: Notify if not UTF-8? -- [Update: Not possible, me thinks]
Replies: 15
Views: 1076

Re: Notify if not UTF-8? -- [Update: Not possible, me thinks]

kunkel321 , a user would likely notice characters being substituted on save. That generally doesn't happen, because the user uses a codepage that includes the characters needed for their language. The real issue is that a sequence of bytes can often be interpreted multiple ways without decoding err...
by Descolada
03 May 2024, 14:12
Forum: Wish List
Topic: Notify if not UTF-8? -- [Update: Not possible, me thinks]
Replies: 15
Views: 1076

Re: Notify if not UTF-8? -- [Update: Not possible, me thinks]

Yeah, turns out file encodings is quite a mess and detecting regular UTF-8 is probably impossible with 100% accuracy. IsTextUnicode exists, but according to multiple StackOverflow posts is rather unreliable. A perhaps more reliable option could be to add a "strict mode" option which would enforce BO...
by Descolada
30 Apr 2024, 23:12
Forum: Bug Reports
Topic: Hotstring O and * options conflict Topic is solved
Replies: 1
Views: 228

Hotstring O and * options conflict Topic is solved

If a hotstring is defined with backspacing disabled, omitting the ending character, and triggering without the ending character, then the last character of the trigger word is deleted. :B0*O:smith::Smith Typing the trigger word "smith" will result in "smitSmith" but the expected result is "smithSmit...
by Descolada
30 Apr 2024, 22:43
Forum: Scripts and Functions (v2)
Topic: AutoCorrect for v2
Replies: 136
Views: 14465

Re: AutoCorrect for v2

kunkel321 :C:smith::Smith works because normal hotstrings suppress the end character and resend it with the replacement. However, the X option doesn't cause the end character to be suppressed, which you can demonstrate with this: :B0X:smith::MsgBox "Hello" . To fix this, add the O option and correc...
by Descolada
29 Apr 2024, 12:35
Forum: Ask for Help (v2)
Topic: Label with no ClassNN. How to find it or read text from Label another way?
Replies: 4
Views: 465

Re: Label with no ClassNN. How to find it or read text from Label another way?

FalseShepard in that case the text is most likely just not accessible. You could try reading the values directly from the programs memory, which would probably be rather difficult. Alternatively try to optimize OCR performance. For example, with the OCR.ahk library you should set the zoom factor to...
by Descolada
28 Apr 2024, 13:45
Forum: Scripts and Functions (v2)
Topic: UIA v2
Replies: 375
Views: 54270

Re: UIA v2

shipaddicted I'm not aware of any UIA method capable of resizing an element. Since you are dealing with a website I'd recommend Javascript injection via the address bar, which would probably be fastest and most reliable. Alternatively if the Edit field can be resized by dragging it from the corner,...
by Descolada
28 Apr 2024, 13:28
Forum: Scripts and Functions (v2)
Topic: Easy OCR
Replies: 93
Views: 18401

Re: Easy OCR

Starkom perhaps something like this: #Requires AutoHotkey v2 #include <OCR> result := OCR.FromRect(406, 261, 87, 36, "en-us") MsgBox eval(RegExReplace(result.Text, "[^\d-+*\\]")) ; Source: https://github.com/TheArkive/eval_ahk2/blob/master/_eval.ahk ; ===============================================...

Go to advanced search