StrokesPlus Forum
                       
StrokesPlus Forum
Home | Profile | Register | Active Topics
Members | Search | FAQ
 All Forums
 General Discussion
 General Discussion
 Windows 10 (1903) / Edge browser / acSendKeys

Note: You must be registered in order to post a reply.
To register, click here. Registration is FREE!

UserName:
Password:
Format Mode:
Format: BoldItalicizedUnderlineStrikethrough Align LeftCenteredAlign Right Horizontal Rule Insert HyperlinkInsert EmailInsert Image Insert CodeInsert QuoteInsert List
   
Message:

* HTML is OFF
* Forum Code is ON
Smilies
Smile [:)] Big Smile [:D] Cool [8D] Blush [:I]
Tongue [:P] Evil [):] Wink [;)] Clown [:o)]
Black Eye [B)] Eight Ball [8] Frown [:(] Shy [8)]
Shocked [:0] Angry [:(!] Dead [xx(] Sleepy [|)]
Kisses [:X] Approve [^] Disapprove [V] Question [?]

 
Check here to subscribe to this topic.
   

T O P I C    R E V I E W
Hard.Wired Posted - 09/30/2019 : 02:35:55
Anyone else having odd problems with Windows 10 (1903) and the Edge browser?

I finally had to succumb to the 1903 upgrade and noticed that some of my S+ acSendKeys commands no longer function reliably. In particular things like "^w", "%{LEFT}" and "%{RIGHT}". They still work correctly in other browsers (Chrome, Firefox, Brave).

Things that make you go... Hmmm.
7   L A T E S T    R E P L I E S    (Newest First)
Hard.Wired Posted - 10/01/2019 : 17:50:12
Thank you, very helpful info. I wonder if it also has something to do with Edge's sandboxing methods? This all may change once the new Edge/Chromium version is officially released. PITA!
Rob Posted - 10/01/2019 : 09:49:26
Note that it's not all Core apps. For example, Calculator has no problem with this even though its hierarchy is basically the same. It's something specific in the Edge architecture/messaging.
Rob Posted - 10/01/2019 : 09:45:25
So what I've found in trying to resolve for S+.net is that when you activate the top level window (ApplicationFrameWindow), it changes the focus to the main body/browser area window of Edge (Windows.UI.Core.CoreWindow). It's during this switch when keyboard input is sent to the top level window (and basically lost), once CoreWindow is active, the input is received fine.

That explains why you send control down works because it sets the keystate globally and buys a little time for CoreWindow to become active. Adding a small delay also seems to work (in S+.net), like acDelay(100) before sending keystrokes to allow CoreWindow to be reactivated and ready to receive input.
Hard.Wired Posted - 10/01/2019 : 01:21:49
Something I just noticed:

Doesn't work...
acSendKeys("^w")

Does work...
acSendControlDown()
acSendKeys("w")
acSendControlUp()

I looked more into Edge's window hierarchy as you mentioned. It was strange before where there would be odd delays when activating the window if it wasn't already in focus, but now it is really weird in 1903 where the order of the hierarchy seems random. I'm sure there is some logic to it (or at least I hope). I'll keep digging.
Hard.Wired Posted - 09/30/2019 : 15:58:12
Drat, spoke too soon. It worked temporarily. Hmm, I'll look into how I am activating the window. Maybe I can find a work around.
Hard.Wired Posted - 09/30/2019 : 14:53:15
Bingo...ish. I was using "Allow After Action Script*", "Allow X1 Click Script*" and "Allow X2 Click Script*", but deactivating X1/X2 finally got things working again. I can live without those for the moment. "After" still seems to work.

Thanks!
Rob Posted - 09/30/2019 : 09:43:32
I don't run the original version anymore obviously, but there is a similar issue in S+.net with the Always Activate Window Where Gesture Began option; if it's enabled the same behavior occurs.

There's something very odd about Edge's window hierarchy. So if you have code (like in before action script) which is trying to activate the Edge window first, that might be the source of the issue...but I cannot say for sure.

StrokesPlus Forum © 2011-2018 Rob Yapchanyk Go To Top Of Page
Snitz Forums 2000