HTMLViewer: Will it ever have DOM access?

In .NET languages, you can access a WebBrowserControl’s Document Object Model and add or remove items. Will Xojo’s HTMLViewer ever have advanced features such as the mentioned DOM access?

Or, is there a plugin that allows you to do this?

[quote=79186:@Shane Gibbs]In .NET languages, you can access a WebBrowserControl’s Document Object Model and add or remove items. Will Xojo’s HTMLViewer ever have advanced features such as the mentioned DOM access?

Or, is there a plugin that allows you to do this?[/quote]

You can do the same with IE web Browser. Add a OLEContainer to your window and Choose ActiveX Control “Microsoft Web Browser”

It’s fairly easy to do using JavaScript.

function ChangeHTML(newHTML) {
var f = document.getElementById("xxx");
f.innerHTML = newHTML;
}

These links might help you.

https://forum.xojo.com/conversation/post/76306
http://documentation.xojo.com/index.php/OLEContainer
http://documentation.xojo.com/index.php/OLEObject

[quote=79189:@Michael Diehr]It’s fairly easy to do using JavaScript.

function ChangeHTML(newHTML) { var f = document.getElementById("xxx"); f.innerHTML = newHTML; } [/quote]

Cool. But having Xojo-native DOM functions would be nice too.

[quote=79191:@John Hansen]These links might help you.

https://forum.xojo.com/conversation/post/76306
http://documentation.xojo.com/index.php/OLEContainer
http://documentation.xojo.com/index.php/OLEObject[/quote]

Nope. Those are Windows only, which defeats the purpose of Xojo. (I’m also on OS X)

Can you post a link to the documentation for the .NET stuff… I have been working on a HTMLViewer class that adds in features (contextual menus, keyboard handling, etc) and make heavy use of the DOM and would be interested in seeing if I can add them to my class…

[quote=79188:@John Hansen] Shane Gibbs In .NET languages, you can access a WebBrowserControl’s Document Object Model and add or remove items. Will Xojo’s HTMLViewer ever have advanced features such as the mentioned DOM access?

Or, is there a plugin that allows you to do this?

You can do the same with IE web Browser. Add a OLEContainer to your window and Choose ActiveX Control “Microsoft Web Browser”[/quote]

[quote=79191:@John Hansen] These links might help you.

https://forum.xojo.com/conversation/post/76306
http://documentation.xojo.com/index.php/OLEContainer
http://documentation.xojo.com/index.php/OLEObject 

[/quote]

Oops… I was a bit to fast this time. I read it as COM access and not DOM access.

Anyhow, If you want to use the native browser on Windows instead of webkit. You might need to create your own HTMLViewer, as some DOM functions is not working in the current HTMLViewer (Like getting the source) when triggered from event “DocumentComplete”

If you create your own HTMLViewer you can use event “DownloadComplete” to get source.