I downloaded the zip file, and I created a new project with a htmlviewer and a pushbutton. The pushbutton Action event is simple:
If DebugBuild = True Then
HtmlViewer1.LoadPage GetFolderItem("").Parent.Child(“index.html”)
Else
HtmlViewer1.LoadPage GetFolderItem("").Child(“index.html”)
End If
It works good in MacOS. I can execute the javascript commands, like this:
Dim jsSrc As String
jsSrc = “document.getElementById(‘saveload’).click();”
HTMLViewer1.ExecuteJavaScript(jsSrc)
But in Windows the html not load correctly. I tried to change the renderer from Native to WebKit but I got the same result.
I tried to recognize all the rows in the html and the javascript files. In the end of the html there is a
This tag not run in Windows.
What is the problem? The program in MacOS works good, without problem, but not in Windows. I tried it in Windopws 10, 7, XP.
Dear Marius!
I tried it with Mozilla Firefox (it works good), this is my default browser. But with Internet Explorer (11.576) and Edge ( 38.14393.0.0) the designer not works. A blank screen appears, without any control.
The linked blog is still not enough. I use these settings to get my HTML Viewer (using IE) work, give it a try, of course you have to replace the filename minicalc.exe with your file:
The Sys.ReadRegistry and Sys.WriteRegistry are my own Objects literally do they named for, b is just a boolean to show me if method ended successfully.
You should consider that modern website protective methods like CSP prevent opening or simply doesn’t work with old browser engines like IE11.
// 32 Bit on 64 Bit System
if cstr(Sys.ReadRegistry("HKEY_LOCAL_MACHINE\\SOFTWARE\\Wow6432Node\\Microsoft\\Internet Explorer\\MAIN\\FeatureControl\\FEATURE_BROWSER_EMULATION","minicalc.exe")) = "" then
b = Sys.WriteRegistry("HKEY_LOCAL_MACHINE\\SOFTWARE\\Wow6432Node\\Microsoft\\Internet Explorer\\MAIN\\FeatureControl\\FEATURE_BROWSER_EMULATION","minicalc.exe",11999,1)
end if
// 32Bit only System (or 64 Bit)
if b=false and cstr(Sys.ReadRegistry("HKEY_LOCAL_MACHINE\\SOFTWARE\\Microsoft\\Internet Explorer\\MAIN\\FeatureControl\\FEATURE_BROWSER_EMULATION","minicalc.exe")) = "" then
b = Sys.WriteRegistry("HKEY_LOCAL_MACHINE\\SOFTWARE\\Microsoft\\Internet Explorer\\MAIN\\FeatureControl\\FEATURE_BROWSER_EMULATION","minicalc.exe",11999,1)
end if
Roland, Have you tried with the HTMLViewer renderer set to Webkit in the Inspector ? Since the renderer on Mac is also Webkit, it seems possible that it works the same.
Roland, you better should use another picture uploading platform, my firewall is blocking this cause it leading to strange russian Ad servers and when opening on other PC I only see porn…
I’m sorry Tomas, I not see any ads, I just want to upload screenshots.
The live demo works with php, but in the github page you can download the javascript-based source code. I downloaded the zip file, I extracted it and I open the index.html with getopenfolderitem.
When I open the index.html with Firefox, it works great. But if I open with IE or Edge, the page not loaded. The same thing, when I open with Xojo, htmlviewer LoadPage.
I can try upload images.