Unable to Render Bootstrap on LabVIEW Front Panel

Updated Mar 31, 2020

Reported In

Software

  • LabVIEW

Operating System

  • Windows

Issue Details

I use the Web Browser Control in LabVIEW to load Bootstrap based web pages on the front panel, similar to the one shown below.



However, LabVIEW fails to render the Bootstrap component of these web pages, resulting in a distortion as displayed below.



The same web page renders correctly when opened directly through a web browser like Internet Explorer. Why does LabVIEW fail to render Bootstrap ?

Solution

The Web Browser Control by default tries to render all web pages using the Internet Explorer 7 (IE7) rendering engine, even though a later version of IE is installed on your system. As the latest Bootstrap version is incompatible with IE7, the web page fails to render correctly on the LabVIEW front panel. However if you directly open the web page on the IE browser, rendering happens through the latest version of IE engine which is installed on your system, which might be compatible with Bootstrap. Thus, Bootstrap renders correctly in this case.

To resolve this problem, you should ensure that the latest version of Internet Explorer is installed on your system and then override the default rendering engine of the LabVIEW Web Browser Control by adding a meta tag in your HTML as described here.

Additional Information

Original versions of ActiveX Web Browser Control used IE7 as the rendering engine. Hence to maintain backwards compatibility, it continues to use IE7 as the default engine. LabVIEW does not play any role here as this is an inherent functionality of the ActiveX control.