We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy. Image for the cookie policy date
Syncfusion Feedback

Trusted by the world’s leading companies

Syncfusion Trusted Companies

Overview

The WinForms HTML Viewer is a WebBrowser control that displays web pages with support for displaying cascade style sheets, loading custom controls etc. It can be used as HTML-based layout engine to easily design and customize rich application interfaces. Like popular web browsers, it comes with advanced options to work with web-related functionalities like navigating through a history of documents, selection and much more.


Load and Display HTML

HTMLUI supports rendering web pages in order to create interactive applications. Like popular web browsers, HTMLUI comes with advanced options to work with web-related issues like navigating through a history of documents, etc. HTMLUI is completely independent from Internet Explorer; this provides full independence in controlling the appearance and settings of the control.

Windows Forms HTMUI display html page like web browsers


Windows Forms HTMUI render user defined html tags

HTML Files from the User Drive

Any HTML file from the user’s drive can be loaded into the HTMLUI control by specifying the location of the document. The HTMLUI control can also load MHTML files from a local drive. Users can customize the HTMLUI control to load documents into it by dragging and dropping them into the control.


HTML from Text

HTMLUI can render HTML contents in the form of text. Also, it is possible to change HTML contents easily at run time with the help of the HTMLUI control. Another feature available in HTMLUI is that the XML document object of the document loaded in the control can be extracted and used by the user for other external applications.

Windows Forms HTMUI display html contents as text


Windows Forms HTMUI display web link

HTMLUI supports linking to various documents either from the user drive or from a URI, which helps in developing user-friendly applications. HTMLUI allows the use of the Tab key shortcut to navigate through the links.

Images can be used instead of text as links to other files in the HTMLUI control. The important feature that HTMLUI provides with links is that users can decide the course of action forwarded by the link after being clicked, with the help of built-in events that are developed with the HTMLUI control.


Stream Files

HTML files associated with a project as an embedded resource can be easily loaded in HTMLUI. Methods are enabled with the HTMLUI control that allow HTML documents to be loaded from a memory stream.

Display html page from memory stream


Host Windows Forms Controls

HTMLUI can expose the control that is present in a specified HTML element. Tracing controls in an HTML document will help developers in creating a powerful interaction environment for users.


HTMUI render windows forms control from html document

Custom Control Using Custom Tags

Custom controls can be created and used just like normal HTML elements with the help of custom tags. The custom tag is a customized HTML tag with class and assembly as its attributes. The assembly attribute refers the namespace of the control, and the class attribute refers the control itself. This is flexible to such an extent that users can use any Windows Forms control in an HTML document and make the application native and productive.


Custom Control Using User-Defined Tag

The other form of using HTMLUI in rendering user-defined controls is by creating a control in the HTML document as an HTML element and interfacing that HTML element with a control available on the form. HTMLUI will take care of the layout of the control interface with the form based on the properties available for it in the HTML document. This method helps in creating applications involving customized layouts and advanced user interactivity.

HTMUI render custom control


Document Tags

The following tags define the major sections of an HTML document.


HTMLUI supports the following formatting related tags: b (bold font text), br (next line), em (emphasize text), font (font formatting options), h1 (header 1), h2 (header 2), h3 (header 3), h4 (header 4), h5 (header 5), h6 (header 6), hr (horizontal rule), code (inline code snippets), strong (bolder text), style (defines the styles for the HTML elements in the document), sub (subscripted text), sup (superscripted text), p (new paragraph), and pre (predefined text).


HTMLUI supports the following HTML tags for layout and customization of elements:

A (link), B (makes text bold), BR (break line), EM (makes text italic), FONT (inline element for text), H1–H6 (tags for heading styling), HR (horizontal line), I (makes text italic), U (underlines text), IMG (displays images), LINK (used for attaching CSS document), SPAN (inline element for applying CSS style), STRONG (makes text bold), STYLE (used for attaching CSS inside HTML document), TITLE (title displayed on control), INPUT (Windows Forms controls, such a button, textbox, etc.), SELECT (list box or combo box win controls), TEXTAREA (multiline text box win control), CHECKBOX (check box win control), RADIO (radio box win control), CODE (inline tag for representing code sample), CUSTOM (interface Windows Forms controls to the HTML elements), CENTER (center align the text), DIV (block tag container), FORM (container for win controls), BODY (container of visual document data), HEAD (container for document’s settings), LI (simple item of a list), LINK (defines link to external document such a CSS document), OL (ordered list container), P (container of text paragraph), PRE (container of formatted text), SCRIPT (container of script code), TABLE (represents table container), TR (container of single row in a table), TD (container of single cell in a table), TH (column header in a table), UL (unordered list container)

Windows Forms HTMLUI formatting tags


Localization

Localizing applications can be made easier by using HTMLUI. The layout and run-time customization capabilities afforded by HTMLUI make it the ideal localization Framework for your applications. When text or images are changed on account of localization, the control will automatically layout the user interface to provide the best experience to the user.


Windows Forms HTMLUI formatting

Skin and Theme Localization

HTMLUI can be used to skin and theme applications to provide an experience beyond typical localization. The entire user interface arrangement can be switched on the fly for different locales.


Cascading Style Sheets

HTMLUI supports the following Cascading Style Sheet (CSS) attributes to be used along with HTML documents: background-color, foreground, vertical-align, cursor, padding, padding-left, padding-top, padding-right, padding-bottom, border, border-left, border-top, border-right, border-bottom, border-style, border-left-style, border-top-style, border-right-style, border-bottom-style, border-width, border-left-width, border-top-width, border-right-width, border-bottom-width, border-color, border-left-color, border-top-color, border-right-color, border-bottom-color, font-family, font-style, font-weight, font-size, text-decoration, width, height, background-image, background-repeat.

Windows Forms HTMLUI style sheet


Windows Forms HTMLUI display xml as html document

Load XML Using XSLT

HTMLUI can display XML documents transformed to HTML using XSLT. In an XSL transformation, both the XML document and an XSLT style sheet are read. Based on the instructions found in the XSLT style sheet, a new HTML document is generated in the output which is then loaded into the HTMLUI control.


Render Web Documents

HTMLUI supports rendering HTML pages from web pages, which helps in the creation of interactive applications involving simple pages. Also, the control supports history options just like the popular web browsers, which help in navigating through the previous HTML pages loaded in the HTMLUI control.

Windows Forms HTMLUI render web documents


Windows Forms HTMLUI scripting

Scripting

Scripting inside an HTML document makes the document self-contained and work independently. HTMLUI supports embedded scripts in HTML code. A user can also define script code in external documents. Scripting is supported in three languages: C#, Visual Basic, and JScript.


Bubbling Events Architecture

Bubbling events architecture is the use of a common event handler declared for a parent HTML element that can be used in handling the same event for all of its child HTML elements. This helps in reducing the task of declaring event handlers for all the elements in a document, thereby reducing the length and complexity of the code.

Click the button rendered in Windows Forms HTMLUI


Windows Forms HTMLUI event list

Interactive Control Events

HTMLUI comes with some events that can be used to access the state of the control at run time. The event handlers for these events are custom developed to help users make the application more informatory and interactive. These events are so powerful that the status and the course of the application can be decided at run time.


Design Properties

HTMLUI exposes design properties like an element’s size, location, etc. Also, users can change the visibility of HTML elements at run time. Powerful graphical applications with the use of HTML documents are feasible with our HTMLUI because of these interactive formatting features.

Windows Forms HTMLUI design properties


Windows Forms HTMLUI custom representation of elements

Events

HTMLUI supports custom representation of elements by handling events. This serves as a powerful medium for the customization of display elements.


Format

HTMLUI comes with a separate class for creating and applying formats to HTML elements. With the help of this formatting option, UI applications with a modern appearance can be created.

Windows Forms HTMLUI formatting


Windows Forms HTMLUI scrolling

Customized Scrolling

HTMLUI supports scrolling that helps users in loading large documents inside the HTMLUI control and navigating to desired locations easily. Users can toggle the scrolling control visibility at run time. Easy methods are enabled so that users can scroll quickly through the document to desired positions.


Keyboard Shortcuts

HTMLUI comes with flexible keyboard support with functionalities similar to those featured in popular browsers. Common options like select all text, find specified text, copy selected text, and tabbing through the control gives HTMLUI a familiar feel and makes it flexible for common tasks.

Windows Forms HTMLUI keyboard shortcuts


Windows Forms HTMLUI text selection

Text Selection

Selecting the text present in a document is supported in HTMLUI. The selected text can be accessed programmatically and searched, or copied to the clipboard to be used in other applications. In addition to text, HTML elements under the selection region can be accessed and coded for efficient UI solutions.


Export Formats

This is an example of how a document available in HTMLUI is converted to an image and used in other Essential Studio applications.


Selecting the text present in a document is supported in HTMLUI. The selected text can be accessed programmatically and searched, or copied to the clipboard to be used in other applications. In addition to text, HTML elements under the selection region can be accessed and coded for efficient UI solutions.

Windows Forms HTMLUI print and preview


Document in HTMLUI are exposed as programmatic elements

Programmatic Access

HTML elements displayed in a document in HTMLUI are exposed as programmatic elements that can be manipulated from the application code. These elements expose standard events such as Click, MouseMove, and MouseDown. The content and appearance of all elements can be changed from within the code.


Source Code

HTMLUI is written in C# and is available with full source code. The source code can be integrated into your development environment for debugging. Samples with source code are provided in C# and VB.NET.




95+ WINDOWS FORMS CONTROLS

Frequently Asked Questions

The Syncfusion WinForms HTML Viewer provides the following:

  • Display web pages with support for displaying cascade style sheets.
  • Develop user-friendly applications with bookmarks linking various documents.
  • Numerous ways to load HTML documents along with custom controls.
  • Inbuilt printing and exporting capabilities. .
  • Seamless CSS support.
  • Localization.
  • Easy searching and highlighting with the inbuilt search option.
  • Simple configuration and API.
  • One of the best WinForms HTML Viewers in the market that offers a feature-rich UI.
  • Extensive demos and documentation to learn quickly and get started with WinForms HTML Viewer.

You can find our WinForms HTML Viewer demo on

GitHub location.

No, this is a commercial product and requires a paid license. However, a free community license is also available for companies and individuals whose organizations have less than $1 million USD in annual gross revenue, 5 or fewer developers, and 10 or fewer total employees.

A good place to start would be our comprehensive getting started documentation.

Our Customers Love Us

Having an excellent set of tools and a great support team, Syncfusion reduces customers’ development time.
Here are some of their experiences.

Rated by users across the globe

Transform your applications today by downloading our free evaluation version
Download Free Trial No credit card required.

Syncfusion Windows Forms Resources

Awards

Greatness—it’s one thing to say you have it, but it means more when others recognize it. Syncfusion is proud to hold the following industry awards.

Up arrow icon