Complete the following steps to implement a new Action VI.
Create a new VI from an Action VI template.
From the custom device LabVIEW project, navigate to Custom Device API.lvlib»Templates»Action VI.
Right-click the Action VI you want to customize and select New from Template.
Save the new Action VI to the same directory as the custom device project. After associating this VI with a custom device item, you will customize the code according to your needs.
Declare the Action VI in the Custom Device XML. You declare the Action VI within the declaration for a specific page. The Action VI executes when a user performs the triggering action on that page.
From the custom device LabVIEW project, open the Custom Device XML file.
Locate the <Page> tags for the custom device item from which you want to call the Action VI.
Declare the Action VI anywhere beneath the <Item2Launch> tag. For the formatting of the declaration, see NI VeriStand Custom Device XML tags. The following example illustrates how to declare the Action VI.
Customize the Action VI to meet your needs.
Add the Action VI to the Configuration build specification of the custom device.
From the custom device LabVIEW project, double-click Build Specifications»Configuration.
Select Source Files from the Category menu.
Under the Project Files menu, locate the Action VI and move it to the Always Included list.
Select Source File Settings from the Category menu.
Select the Action VI from the Project Files menu.
From the Destination pull-down menu, select the Configuration LLB.