Accesing Host Aplication Function via VBScript.

basapa

Member
Joined
Apr 4, 2003
Messages
8
Hello, ive read some threads about how to catch HTML events in a VB.Net application that have a WebBrowser component.

In Microsoft documentation i saw it possibile to access host functions from HTML scripts "window.external".

But Im not able to do this. I found examples in C# on Microsoft site.

Do you know if its possible to do the same using Vb.Net.?

Thanks to all.

Sorry for my english.
 
VB can do everything C# can (except for Unmanaged code) so all you have to do is translate it into VB or create a C# DLL project and put the code there
 
I cannot

I have only Vb.Net, so i cannot create C# project and use the Dll in my Vb.Net Project.

I cannot traduce c# code to VB.Net code because the c# code use an Interface that is not accessible via VB.Net
 
You have to find an assembly where that interface is defined, and unfortunately there isnt a public one in the framework. Interopping with MSHTML like this is not easy, and you end up having to define a lot of interfaces yourself with their GUIDs.

If you just want your application to respond to HTML events, search this forum for "html events".
 
Events

Ive just read thread about events but id like to use my own function without using events to access my own code.

I want to use window.external capabilities of MSHTML

Thanks
 
Back
Top