Skip to content

Comments

018-BasicFramesDemo.au3#101

Draft
mlipok wants to merge 6 commits intoioa747:mainfrom
mlipok:FrameDemo
Draft

018-BasicFramesDemo.au3#101
mlipok wants to merge 6 commits intoioa747:mainfrom
mlipok:FrameDemo

Conversation

@mlipok
Copy link
Contributor

@mlipok mlipok commented Feb 17, 2026

Important

Thanks for your effort and interest 💛 in improving the project. It's very appreciated.

Description

new example to show and test frames support

🔗 Linked GitHub Issues

#91

Closes #\91

📋 What is the current behavior?

no example to frames support

🚀 What is the new behavior?

just new example


Type of changes

  • 🪲 Bugfix (change which fixes an issue)
  • ⭐ New Feature (change which adds functionality)
  • ⭐ New Example (this PR adds a new example)
  • 🔒 Security fix (change which improves security)
  • 🔮 Code style update (formatting, renaming)
  • 🔨 Refactoring (code optimization without functional change)
  • 📚 Documentation (updates to README or docs)
  • ⚙️ Build or CI related changes
  • 🧿 Other type

Breaking changes 🔥

  • Yes
  • No

How and where was this tested?

🖥️ Describe where you tested your changes

System:

  • Windows 11 (x64)
  • Windows 10 (x64)
  • Windows 10 (x86)
  • Windows Server ......

Context:

  • COM object NetJson.Parser
  • COM object NetWebView2.Manager - WebView2
  • COM object NetWebView2.Manager - Bridge
  • UDF - NetWebView2Lib.au3
  • Examples: 018-BasicFramesDemo.au3
  • with ...

🔬 Describe how you tested your changes

  • Manually tested in system and context shown above
  • Ran automatic tests (unit tests, integration tests, etc.)
  • Other ways

Checklist

  • I have read and understood the available contributing guidelines.
  • I have ensured my code follows the available code conventions.
  • I have reviewed my changes.
  • I have made corresponding changes to the documentation (if applicable).
  • I have added/updated necessary tests to cover the changes (if applicable).
  • I have checked for potential security implications.

Additional context

noen

Screenshots

none

Note to reviewers

Important

Do not close this before I say that all is done

This PR will became an testing place - forum for discussion
At the end we will have good example

@mlipok
Copy link
Contributor Author

mlipok commented Feb 17, 2026

As you can notice this example will use template for other project that I was involved in the past:

#COMMENT This example is based on ==> ;	https://github.com/Danp2/au3WebDriver/blob/1834e95206bd4a6ef6952c47a1f1192042f98c0b/wd_demo.au3#L588-L732

https://github.com/Danp2/au3WebDriver/blob/1834e95206bd4a6ef6952c47a1f1192042f98c0b/wd_demo.au3#L588-L732

and it is based on:
https://www.w3schools.com/tags/tryit.asp?filename=tryhtml_iframe

@mlipok
Copy link
Contributor Author

mlipok commented Feb 17, 2026

My results are:

	ConsoleWrite("! " & @ScriptLineNumber & " : Frames=" & $iFrameCount & @CRLF)
	For $IDX_Frame = 0 To $iFrameCount -1
		ConsoleWrite("- IDX=" & $IDX_Frame & @CRLF)
		ConsoleWrite("- URL=" & $oWebV2M.GetFrameUrl($IDX_Frame) & @CRLF)
		ConsoleWrite("- NAME=" & $oWebV2M.GetFrameName($IDX_Frame) & @CRLF)
		ConsoleWrite(@CRLF)
	Next

result - I think that here something is not quite well:

! 59 : Frames=4
- IDX=0
- URL=Unknown
- NAME=iframeResult

- IDX=1
- URL=Unknown
- NAME=__tcfapiLocator

- IDX=2
- URL=Unknown
- NAME=

- IDX=3
- URL=Unknown
- NAME=
	ConsoleWrite("! " & @ScriptLineNumber & " : GetFrameUrls() :" & @CRLF & $oWebV2M.GetFrameUrls() & @CRLF)
	ConsoleWrite("! " & @ScriptLineNumber & " : GetFrameNames() :" & @CRLF & $oWebV2M.GetFrameNames() & @CRLF)

result - I think that here something is not quite well:

! 67 : GetFrameUrls() :
Unknown|Unknown|Unknown|Unknown
! 68 : GetFrameNames() :
iframeResult|__tcfapiLocator||
	For $IDX_Frame = 0 To $iFrameCount - 1
		ConsoleWrite(@CRLF & "======================================================" & @CRLF)
		ConsoleWrite("! " & @ScriptLineNumber & " : GetFrameHtmlSource(" & $IDX_Frame & ") :" & @CRLF & $oWebV2M.GetFrameHtmlSource($IDX_Frame) & @CRLF)
	Next
	ConsoleWrite(@CRLF & "======================================================" & @CRLF)

results for GetFrameHtmlSource(IDX) puts results in message handler instead returns them to the Au3 script directly as a result of GetFrameHtmlSource(IDX) methode.

Please change it

======================================================
! 71 : GetFrameHtmlSource(0) :

+> ( NetWebView2Lib UDF : SLN=1643 ) :: [EVENT: OnMessageReceived]: GUI:[HANDLE:0x00000000001F0BCE] ! UNKNOWN MESSAGE:FRAME_HTML_SOURCE|0|<html data-darkreader-mode="dynamic" data-darkreader-scheme="dimmed"><head><style class="darkreader darkreader--fallback" media="screen"></style><style class="darkreader darkreader...

======================================================
! 71 : GetFrameHtmlSource(1) :


======================================================
! 71 : GetFrameHtmlSource(2) :


======================================================
! 71 : GetFrameHtmlSource(3) :


======================================================


+> ( NetWebView2Lib UDF : SLN=2050 ) :: [EVENT: OnAcceleratorKeyPressed]: GUI:[HANDLE:0x00000000001F0BCE] $oArgs: [VirtualKey=27; KeyEventKind=1; Handled=False; RepeatCount=1; ScanCode=1; Is...
+> ( NetWebView2Lib UDF : SLN=1643 ) :: [EVENT: OnMessageReceived]: GUI:[HANDLE:0x00000000001F0BCE] ! UNKNOWN MESSAGE:FRAME_HTML_SOURCE|1|<html data-darkreader-mode="dynamic" data-darkreader-scheme="dimmed" data-darkreader-proxy-injected="true"><head><style class="darkreader darkreader--fallback" media="screen"></sty...
+> ( NetWebView2Lib UDF : SLN=1643 ) :: [EVENT: OnMessageReceived]: GUI:[HANDLE:0x00000000001F0BCE] ! UNKNOWN MESSAGE:FRAME_HTML_SOURCE|2|<html dir="ltr" lang="pl" data-darkreader-mode="dynamic" data-darkreader-scheme="dimmed" style="height: 100%; width: 100%;" data-darkreader-proxy-injected="true"><head><style class...
+> ( NetWebView2Lib UDF : SLN=1643 ) :: [EVENT: OnMessageReceived]: GUI:[HANDLE:0x00000000001F0BCE] ! UNKNOWN MESSAGE:FRAME_HTML_SOURCE|3|<html data-darkreader-mode="dynamic" data-darkreader-scheme="dimmed"><head><style class="darkreader darkreader--fallback" media="screen"></style><style class="darkreader darkreader...
image

@mlipok
Copy link
Contributor Author

mlipok commented Feb 18, 2026

@ioa747 what do you think here ?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant