Download Source Code – 125 Kb

The Windows application above will allow you to view a web page and the HTML source at the same time.
The application consists of an IE Web Browser control (top section) and a multi-line text box control (bottom section). You enter or select a URL using the combo box control and then select the “Go” button. The Browser control will navigate to the URL and display the web page. When you select the “Get Source” button, the bottom section of the Windows application displays the HTML source for the web page.
The Microsoft Web Browser control adds browsing, document, viewing, and downloading capabilities to your applications. Parsing and rendering of HTML documents in the browser control is handled by the MSHTML component. Before you can use the Browser control in a Windows application, you must add a reference to the “Microsoft HTML Object Library” (mshtml) to get to the interfaces and classes.
You can get the full source code for the application by selecting the Download Source Code link.