Delphi Delphi Programming
How to install TWebBrowser
The Active-X component TWebBrowser is a wrapper providing access to Microsoft's Internet Explorer, which allows you to embed a copy of Internet Explorer on a form.
To install it (so that it can be used within the Delphi environment), the Active-X control must be imported into Delphi:
- Start up Delphi.
- On the "Component" menu in the main toolbar select "Import ActiveX Control..."
- In the list box scroll and and select "Microsoft Internet Controls".
The "Class names" should then list "TWebBrower".
Note: If you have Internet Explorer 4 or later then you will have two components appear -
WebBrowser_V1provides backwards compatibility with Internet Explorer 3, and in general in your code you should use
- For the "Palette Page" either leave it as "ActiveX" or select "Internet" - according to which toolbar you would like the TWebBrowser control to appear on.
- Click "Install..." (not "Create Unit")
- Then click "OK" on the "Install" form that appears and "Yes" on the confirm prompt.
The TWebBrowser component will now appear on the ActiveX (or Internet) component tab and be available for use.
These notes are believed to be correct for Delphi 6 and Delphi 7, with Internet Explorer 6, and may apply to other versions as well.
About the author: Brian Cryer is a dedicated software developer and webmaster. For his day job he develops websites and desktop applications as well as providing IT services. He moonlights as a technical author and consultant.