How to add web browser into a form?

Forums for specific tips, techniques and example code
ConvertFromOldNGs
Posts: 5321
Joined: Wed Aug 05, 2009 5:19 pm

How to add web browser into a form?

Postby ConvertFromOldNGs » Fri Aug 07, 2009 2:49 pm

by Thomas. >> Sun, 25 Jan 2004 14:41:41 GMT

Hi How can I add a web browser into a form? Thanks

ConvertFromOldNGs
Posts: 5321
Joined: Wed Aug 05, 2009 5:19 pm

Re: How to add web browser into a form?

Postby ConvertFromOldNGs » Fri Aug 07, 2009 2:49 pm

by allistar >> Mon, 26 Jan 2004 7:32:36 GMT

Hi there,
Sounds like you would need some sort of COM control that gets added to the form.

You can get a hold of the COM (aka ActiveX) Mozilla component from:

http://www.iol.ie/~locka/mozilla/mozilla.htm

Read more about it here:

http://www.iol.ie/~locka/mozilla/control.htm

This component is free (in the sense of cost and also the source code for it is avaulable). It uses the popular Gecko rendering engine that is used is many standards based web browsers.

You should be able to install this component and drop it onto a JADE form to display web pages in your JADE application.

I hope this helps,
Allistar.
--
------------------------------------------------------------------
Allistar Melville
Software Developer, Analyst allistar@silvermoon.co.nz
Auckland, NEW ZEALAND

Silvermoon Software
Specialising in JADE development and consulting
Visit us at: http://www.silvermoon.co.nz
*NEW* Simple web access to Jade at: www.silvermoon.co.nz/jhp.html ------------------------------------------------------------------

ConvertFromOldNGs
Posts: 5321
Joined: Wed Aug 05, 2009 5:19 pm

Re: How to add web browser into a form?

Postby ConvertFromOldNGs » Fri Aug 07, 2009 2:49 pm

by Thomas. >> Tue, 27 Jan 2004 3:48:48 GMT

Thank you allistar - Which documents from Mozilla should I read? What is the next step after importing ActiveX control? I drop it on the form and How to code it? sorry for many questions.

ConvertFromOldNGs
Posts: 5321
Joined: Wed Aug 05, 2009 5:19 pm

Re: How to add web browser into a form?

Postby ConvertFromOldNGs » Fri Aug 07, 2009 2:49 pm

by allistar >> Tue, 27 Jan 2004 21:34:29 GMT

Hi,
I have never used it before (never needed to) but you can find documentation for it at http://www.iol.ie/~locka/mozilla/control.htm.

It should be a matter of putting the control on your form and then calling methods/setting properties on that control to display HTML pages.

Regards,
Allistar.
--
------------------------------------------------------------------
Allistar Melville
Software Developer, Analyst allistar@silvermoon.co.nz
Auckland, NEW ZEALAND

Silvermoon Software
Specialising in JADE development and consulting
Visit us at: http://www.silvermoon.co.nz
*NEW* Simple web access to Jade at: www.silvermoon.co.nz/jhp.html ------------------------------------------------------------------

ConvertFromOldNGs
Posts: 5321
Joined: Wed Aug 05, 2009 5:19 pm

Re: How to add web browser into a form?

Postby ConvertFromOldNGs » Fri Aug 07, 2009 2:49 pm

by Stephen Persson >> Fri, 30 Jan 2004 0:34:11 GMT

We use an ActiveX product from EzTools called Web On Windows (WOW).

It is an extremely good product that we have had no problems with. They even added a new feature for us when I contacted their support. It is an active X control that you can place on a form then use to load either a url, or raw html. We use it extensively throughout our application, mainly for viewing html emails sent to clients, or previewing html emails before we send them. We just load back in the raw html that was sent (or to be sent), it does not have to be a physical page on a webserver somewhere.
You can also receive events back within your windows application, when the user clicks a link within the webpage, so your application can handle it rather than linking off another webpage. Again, a very useful feature we use a bit too.

Extremely easy to get up and running - place on a form and literally one line of code to get it working : Set the url property
browser.uRL := "http://www.tenderlink.com";
or load the raw html code
browser.loadHTML("<html><body>Hello world</body></html>");

Worth checking out - works for us anyway.
http://www.eztools-software.com/fr.asp?l=/products.asp
Stephen Persson

ConvertFromOldNGs
Posts: 5321
Joined: Wed Aug 05, 2009 5:19 pm

Re: How to add web browser into a form?

Postby ConvertFromOldNGs » Fri Aug 07, 2009 2:49 pm

by Thomas >> Sat, 31 Jan 2004 20:25:04 GMT

Hi ,,Where can I place my the one line code" browser.uRL := "http://www.tenderlink.com";
or load the raw html code
browser.loadHTML("<html><body>Hello world</body></html>");"

and How many control do I have to place on the form?
Thanks

ConvertFromOldNGs
Posts: 5321
Joined: Wed Aug 05, 2009 5:19 pm

Re: How to add web browser into a form?

Postby ConvertFromOldNGs » Fri Aug 07, 2009 2:49 pm

by Stephen Persson >> Mon, 2 Feb 2004 2:25:45 GMT

There is only one control to add the form.
After you have done the ActiveX import to import the control, you should have an extra button on your Painter menu bar called "WOW2Ctl". This is the only control you need to add to your form.

Where you place the code depends on exactly what you are trying to achieve. You could just place it within the load method on the form :
load() updating;begin

browser.uRL := "http://www.tenderlink.com"; //where browser is the name of my control end;

Or you could make a basic browser by adding a text box and button to your form. Then on the click method of the button you could load whatever url has been typed into the text box:
bGo_click(btn: Button input) updating;begin

browser.uRL := textbox.text;
end;

ConvertFromOldNGs
Posts: 5321
Joined: Wed Aug 05, 2009 5:19 pm

Re: How to add web browser into a form?

Postby ConvertFromOldNGs » Fri Aug 07, 2009 2:49 pm

by Thomas >> Mon, 2 Feb 2004 4:14:28 GMT

thank you very much.


Return to “Tips and Techniques”

Who is online

Users browsing this forum: No registered users and 12 guests