1. Daniel Vivier
  2. PowerBuilder
  3. Thursday, 3 March 2022 16:18 PM UTC

Given what today's Appeon newsletter says, it appears that we will no longer be able to use the MS WebBrowser ActiveX control after sometime in June. (If anyone knows that that is not correct, please let us know!) We use it for significant mail-merge functionality (including for editing templates in DesignMode) in our programs.

Can the new PB Chromium-based WebBrowser control be put into DesignMode using the standard document.DesignMode = "on" method?

I'm worried about having to include that control though in our applications, because it is quite huge (as I recall from looking at it quite a while ago, the required files would add about 90MB to our currently only 30MB program installer!).

So I'm wondering why we wouldn't get as good or better results from just using the MS WebView2 control (the basis of Edge), which is included in Windows anyways, with an ActiveX wrapper. I see there is a commercial such wrapper available at https://webshop.antwise.com/home/10-antview-ms-edge-webview2-activex.html. I haven't figured out how to download an evaluation of it yet but I'm sure it must be way smaller than 90MB! (Yes, we'd have to pay for it, per developer, but it's royalty-free.)

Also, using a wrapper on WebView2 means we would always be accessing the latest MS control rather than the version of Chromium that happens to be included with whichever PB release we are on. That seems like it would also be an advantage.

Your thoughts? Thank you.

Kai Zhao @Appeon Accepted Answer Pending Moderation
  1. Friday, 4 March 2022 09:05 AM UTC
  2. PowerBuilder
  3. # 1

Hi Dan,

For the PowerBuilder WebBrowser control, you can use a script like the below to set the DesignMode.
wb_test.EvaluateJavascriptSync('document.designMode="on"')

You can use the function EvaluateJavascriptSync/EvaluateJavascriptASync of WebBrowser control to execute JavaScript to interact with the webpage. Please refer to the articles below for details.
https://docs.appeon.com/pb2021/powerscript_reference/EvaluateJavascriptSync_func.html
https://docs.appeon.com/pb2021/powerscript_reference/EvaluateJavascriptAsync_func.html

Regards,
Kai

Comment
There are no comments made yet.
Daniel Vivier Accepted Answer Pending Moderation
  1. Thursday, 3 March 2022 21:15 PM UTC
  2. PowerBuilder
  3. # 2

I think I have come to the conclusion that having to replace the use of the WebBrowser ActiveX control is a non-issue.

According to https://techcommunity.microsoft.com/t5/windows-it-pro-blog/internet-explorer-11-desktop-app-retirement-faq/ba-p/2366549 (and also https://en.wikipedia.org/wiki/MSHTML) the MSHTML component (which as I understand it is the same as the WebBrowser control) will be supported until 2029. 

So there is no absolutely need for any applications using it to make a change by this June.

Comment
  1. Daniel Vivier
  2. Friday, 4 March 2022 01:17 AM UTC
And I just got a confirmation of that from a Microsoft staffer: MSHTML, which includes the Web Browser control, is not going away until at least 2029: https://techcommunity.microsoft.com/t5/windows-it-pro-blog/internet-explorer-11-desktop-app-retirement-faq/bc-p/3247052/emcs_t/S2h8ZW1haWx8bWVudGlvbl9zdWJzY3JpcHRpb258TDBCT0UxNFBXQ09WQVp8MzI0NzA1MnxBVF9NRU5USU9OU3xoSw#M3908
  1. Helpful 2
  1. Richard Shakour
  2. Friday, 4 March 2022 15:32 PM UTC
I uninstalled IE11 on a Windows 10 Machine and the browser control still works so I can confirm the above is accurate from what I have tested.
  1. Helpful 1
There are no comments made yet.
Roland Smith Accepted Answer Pending Moderation
  1. Thursday, 3 March 2022 18:21 PM UTC
  2. PowerBuilder
  3. # 3

The quoted price of 361.79 Euros includes 21% VAT so customers outside the EU will get that removed at checkout.

Comment
  1. Daniel Vivier
  2. Thursday, 3 March 2022 18:41 PM UTC
Thanks Roland I saw that too but what I'm really looking for is opinions about whether or why this might be a better approach than using the PB WebBrowser control. And maybe responses from anyone who had already tried it (particularly turning on DesignMode), either with this ActiveX wrapper or another one, and how that worked for them!
  1. Helpful
  1. Roland Smith
  2. Thursday, 3 March 2022 18:47 PM UTC
The website doesn't say whether it supports design mode.

I agree that it would be better for Appeon to use the WebView2 control installed into Windows instead of CEF. WebView2 wasn't available when they developed the WebBrowser control so they went with what was available.
  1. Helpful 1
There are no comments made yet.
  • Page :
  • 1


There are no replies made for this question yet.
However, you are not allowed to reply to this question.