Reputation: 499
What I am looking for here is a way to possibly click a button inside a web browser control and have it call a sub from inside the program or have the program react to something on the page.
I am trying to make a HTML5 GUI for my application. I don't really want use any 3rd party API's to handle commands from a HTML5 interface but if I can find another alternative that would be good. But if there is no other way I would be content with using a 3rd party API.
Upvotes: 1
Views: 1283
Reputation: 163538
The way I have done this in the past is to specify a special protocol for my app.
yourapp:somefunction/someparameter
Handle the Navigating
event, and in your code for when that event is fired, check to see if the URL has your protocol on the front of it. If it is, set e.Cancel = true
to cancel navigation, and add code to handle the URL parameters yoruself.
Upvotes: 2