Search found 39 matches
- 26 Feb 2023, 08:22
- Forum: Scripts and Functions (v2)
- Topic: WebView2
- Replies: 139
- Views: 34325
Re: 2.0-beta.1 - WebView2
class SyncHandler extends WebView2.Handler { __New(cb := 0) { this.obj := SyncHandler.CompletedEventHandler() this.obj.cb := cb super.__New(this.obj, 3) } wait() { o := this.obj while !o.status Sleep(10) o.status := 0, Sleep(100) } class CompletedEventHandler { status := 0, cb := 0 call(handler, ar...
- 30 Nov 2022, 22:02
- Forum: Scripts and Functions (v2)
- Topic: WebView2
- Replies: 139
- Views: 34325
Re: 2.0-beta.1 - WebView2
Thank you so much!!.. Can't wait to till I post working sample..
- 23 Nov 2022, 00:42
- Forum: Scripts and Functions (v2)
- Topic: WebView2
- Replies: 139
- Views: 34325
Re: 2.0-beta.1 - WebView2
Thank you for informative reply.. I am researching second method.. connect via debugger.. While reading a lot of docs.. especially: https://learn.microsoft.com/en-us/microsoft-edge/webview2/reference/win32/webview2-idl?view=webview2-1.0.1293.44#createcorewebview2environmentwithoptions Any idea how t...
- 21 Nov 2022, 14:31
- Forum: Scripts and Functions (v2)
- Topic: WebView2
- Replies: 139
- Views: 34325
Re: 2.0-beta.1 - WebView2
Hi all,
Does anyone has working sample of connecting to existing WebView2 and getting data from page.. Something like that was done with WBGet() function:
Thank you in advance.
Does anyone has working sample of connecting to existing WebView2 and getting data from page.. Something like that was done with WBGet() function:
Code: Select all
wb := WBGet("Page Title")
streetAddress:= wb.document.getElementById("strAddress").value
- 09 May 2022, 23:33
- Forum: Scripts and Functions (v2)
- Topic: WebView2
- Replies: 139
- Views: 34325
Re: 2.0-beta.1 - WebView2
I am so confused, I am not able to perform simple action, such as pressing button, timing issue?: g := Gui() g.Show(Format("w{} h{}", A_ScreenWidth * 0.6, A_ScreenHeight * 0.6)) wv := WebView2.create(g.Hwnd) nav_sync := SyncHandler() exec_sync := SyncHandler((args) => OutputDebug(StrGet(args[2]))) w...
- 02 May 2022, 23:07
- Forum: Scripts and Functions (v2)
- Topic: WebView2
- Replies: 139
- Views: 34325
Re: 2.0-beta.1 - WebView2
thqby Thank you for great reply.. It will take me some time to dissect the code.... Need to learn more about classes.. However, just want to let you know your code seems much faster, but it fails at about at least 50% of the time (vs. 100% accuracy with my sample). The code fails on the last page w...
- 30 Apr 2022, 22:09
- Forum: Scripts and Functions (v2)
- Topic: WebView2
- Replies: 139
- Views: 34325
Re: 2.0-beta.1 - WebView2
Update to my previous post: I have messed around with the code and was able to navigate to www.autohotkey.com click on "documentation" link and then on documentation page click on "search". Then set search text to "testing" . The script works. :dance: :dance: However, the code does not seem right to...
- 29 Apr 2022, 22:10
- Forum: Ask for Help (v2)
- Topic: Continuation section with Variables
- Replies: 4
- Views: 1473
Re: Continuation section with Variables
@swagfag
Thank you so much. One more time Format() saves the day. Seems Format() is very powerful for V2.. Need to master it.
Thank you.
P.
Thank you so much. One more time Format() saves the day. Seems Format() is very powerful for V2.. Need to master it.
Thank you.
P.
- 28 Apr 2022, 09:59
- Forum: Scripts and Functions (v2)
- Topic: WebView2
- Replies: 139
- Views: 34325
Re: 2.0-beta.1 - WebView2
I have made an auto-log in form with WebView2, but have trouble proceeding after log-in... To simplify things, I made an example, this will load the page and clicks "documentation" on autohotkey.com.. How do I proceed after, if I would like to click on "search" or anything else? Do i have to call wv...
- 28 Apr 2022, 00:30
- Forum: Ask for Help (v2)
- Topic: Continuation section with Variables
- Replies: 4
- Views: 1473
Continuation section with Variables
In AHK1.1 I have used something like with expressions: script = ( document.querySelector('#userId').value = '%user%' ) s.text := script in AHKV2, i am stuck on script := ' ( document.querySelector('#userId').value = 'user' )' No expression mode... this is just one liner example for simplicity, I nee...
- 25 Apr 2022, 22:35
- Forum: Scripts and Functions (v2)
- Topic: WebView2
- Replies: 139
- Views: 34325
Re: 2.0-beta.1 - WebView2
It is possible to convert WebView2.ahk to AHK V1.1 (current version)? If yes, how hard it is convert from V2 to V1.1 AHK.. The reason why I am asking, ALL of my scripts and work are v1.1 Any ideas?
- 25 Apr 2022, 22:30
- Forum: Scripts and Functions (v2)
- Topic: WebView2
- Replies: 139
- Views: 34325
Re: 2.0-beta.1 - WebView2
@Tre4shunter
Sorry, I misunderstood your question. Here is a bit better way, but its not 100% what you are looking for. Basically show window off screen. +ToolWindow will remove taskbar entry..
Sorry, I misunderstood your question. Here is a bit better way, but its not 100% what you are looking for. Basically show window off screen. +ToolWindow will remove taskbar entry..
Code: Select all
g := Gui("+Resize +ToolWindow")
g.Show('w600 h500 x-700 y-1000')
- 25 Apr 2022, 09:46
- Forum: Scripts and Functions (v2)
- Topic: WebView2
- Replies: 139
- Views: 34325
Re: 2.0-beta.1 - WebView2
@Tre4shunter
This works for me and seems as a clean way (unless I didn't understood the question correctly):
This works for me and seems as a clean way (unless I didn't understood the question correctly):
Code: Select all
F4::g.Hide()
F5::g.Show()
- 25 Apr 2022, 09:33
- Forum: Scripts and Functions (v2)
- Topic: WebView2
- Replies: 139
- Views: 34325
- 22 Apr 2022, 21:50
- Forum: Scripts and Functions (v2)
- Topic: WebView2
- Replies: 139
- Views: 34325
Re: 2.0-beta.1 - WebView2
Thank you so much.. This works wonderful!! #SingleInstance Force #Include WebView2.ahk g := Gui() g.Show('w600 h500') wv := WebView2.create(g.Hwnd) wv.CoreWebView2.add_NavigationCompleted(WebView2.Handler(NavigationCompletedEventHandler)) wv.CoreWebView2.Navigate('https://autohotkey.com') Navigation...
- 19 Apr 2022, 22:47
- Forum: Scripts and Functions (v2)
- Topic: WebView2
- Replies: 139
- Views: 34325
Re: 2.0-beta.1 - WebView2
I am still trying to figure out how to manipulate webpages with AHK-->WebVIew2 and after research discovered that DOM can be manipulated with ExecuteScriptAsync(). However, I don't see any reference to this method in WebView2.ahk The only something similar to this that I have seen is wv.ExecuteScrip...
- 11 Apr 2022, 23:19
- Forum: Scripts and Functions (v2)
- Topic: WebView2
- Replies: 139
- Views: 34325
Re: 2.0-beta.1 - WebView2
Thank you for teply. it possible to post an example of wv interacting with external website? Like clicking a button and sending text to a external form (external meaning page was not created by self, eg google.com)
- 08 Apr 2022, 09:40
- Forum: Scripts and Functions (v2)
- Topic: WebView2
- Replies: 139
- Views: 34325
Re: 2.0-beta.1 - WebView2
The official version of edge is not available. You need a beta or dev version of edge or edge runtime to use webview2. @userXeo1 thqby Thank you for reply.. Looks like the app had a fixed version of WebView2 runtime installed. So, it didn't work for me until I have specified the path in the script ...
- 04 Apr 2022, 23:32
- Forum: Scripts and Functions (v2)
- Topic: WebView2
- Replies: 139
- Views: 34325
Re: 2.0-beta.1 - WebView2
Hi all..Thank you @thqby I am puzzled about Webview2 runtime. I'm trying to use Webview2 to help me with setting up ahk app and auto logins.. my environment is restricted that devtools (for automation) )in the edge are disabled.. We have an application that uses WebView2.. However, when I have run W...
- 20 Mar 2022, 20:12
- Forum: Ask for Help (v1)
- Topic: ActiveScript.ahk error
- Replies: 2
- Views: 413
Re: ActiveScript.ahk error
Thank you so much for pointing out, and It didn't even crossed my mind. .. Have to be careful these days, since V2 is getting more popular.. I appreciate your help..