Embedding a VI in an Existing HTML Document

National Instruments recommends you use the Web Publishing Tool to create an HTML document and embed VIs so a client computer can view and control the front panel of the VI in a Web browser.

However, if you already have an HTML document, use the following syntax to embed a VI in the HTML document so a client computer can view and control the front panel of the VI in a browser. Include the parameter in brackets [ ] if the VI you want clients to view and control is located on a remote computer. Refer to Syntax Examples for examples of embedding VIs in HTML documents.

Note  If your clients access the VIs using the LabVIEW ActiveX Control you need only to include the <OBJECT> tag information. If they access the VIs using the Netscape plug-in, you need only to include the <EMBED> tag information. However, to best support all potential clients with various configurations, you should include both the <OBJECT> and <EMBED> tags. This makes sure all clients can access the VIs remotely using a browser.

<OBJECT ID="LabVIEWControl" CLASSID="CLSID:A40B0AD4-B50E-4E58-8A1D-8544233807AA" WIDTH=x HEIGHT=x> <PARAM name="LVFPPVINAME" value=VI_NAME> [<PARAM name="server" value=COMPUTER_NAME or IPADDRESS>]
<EMBED SRC=".LV_FrontPanelProtocol.rpvi" LVFPPVINAME=VI_NAME TYPE="application/x-labviewrpvi" WIDTH=x HEIGHT=x></EMBED></OBJECT>

The following list describes the parameters you must configure.

OBJECT WIDTHWidth of the front panel in pixels.
OBJECT HEIGHTHeight of the front panel in pixels.
VI_NAMEThe name of the VI, such as Example.vi.
COMPUTER_NAME or IPADDRESSIf the VI is located on a remote computer, you must supply the domain name of the computer, such as http://foo or the IP address of the computer, such as http://130.164.76.753.
EMBED SRCIf the VI is located on the local computer, set this parameter to .LV_FrontPanelProtocol.rpvi. If it is located on a remote computer accessible through the computer name, set the parameter to http://foo/.LV_FrontPanelProtocol.rpvi, where foo is the computer name. If it is accessible through the IP address, set the parameter to http://IPADDRESS/.LV_FrontPanelProtocol.rpvi, where IPADDRESS is the IP address.
VI_NAMEThe name of the VI, such as Example.vi.
EMBED WIDTHWidth of the front panel in pixels.
EMBED HEIGHTHeight of the front panel in pixels.