Articles in this section
Category / Section

How to load CSS styles to an html document in which available in the form of string into the WinForms HTMLUI control?

1 min read

CSS styles

The CSS styles available in the string can be loaded into the html document with the help of LoadCSSFromString(string) method. These styles are being applied to the document at runtime when needed.

C#

string css = "BODY{background-color:orange;}";
this.htmluiControl1.LoadCSSFromString(css);

 

VB

Private css As String = "BODY{background-color:orange;}"
Me.htmluiControl1.LoadCSSFromString(css)

 

Reference link: https://help.syncfusion.com/windowsforms/html-viewer/style-sheets-css

Did you find this information helpful?
Yes
No
Help us improve this page
Please provide feedback or comments
Comments (0)
Please sign in to leave a comment
Access denied
Access denied