ActiveX control on Web page

How do I get an activeX control on a web page?

A simple example would be great.

The browser would have to support it. And it would have to be loaded from the user’s computer. Not sure that’s gonna work.

You will have to use the HTML OBJECT tag…

(Remember to detect for the system OS since ActiveX is Windows specific and the app won’t render for Mac or Linux)

You could create a custom wrapper using the WebControlWrapper class in web edition to load your ActiveX control. See WebSDK for that. It’s easier than you think if you’ve never played with the WebSDK (look in the extras folder in your Xojo installation for the WebSDK folder with pdf help guide and examples).

You’ll want to primarily use the SetupHTML event handler to return the html that loads the control;

//Something like: Return "<div id='" + me.controlid + "'>" +_ THE_EXACT_HTML_TO_MAKE_THE_ACTIVEX_CONTOL +_ "</div>" //In the SetupHTML event will do the trick.

and assign a constant in the WebControlWrapper class you create, called JavascriptNamespace (required to work), giving it a string value of something like Darren.MyActiveXControlName (anything unique really).

The HTML portion can be learned from here:

Take a look and if you need a physical demo constructed I’m sure it wouldn’t be a problem :-).