Academic Company Events NI Developer Zone Support Solutions Products & Services Contact NI MyNI

Document Type: Example Program
NI Supported: Yes
Publish Date: Apr 2, 2007


Feedback


Yes No

Related Categories

Related Links - Developer Zone

Related Links - Products and Services

Handling User Interaction with DIAdem SUD Dialogs

0 ratings | 0.00 out of 5
Print

Downloads

Filename: user_decision_making_diadem.zip
Requirements: View

This EPD shows how to build user interaction into a VB script in DIAdem.  One of the most common examples of this is when you want the user to be able to check between a number of choices to determine which action to perform.  DIAdem saves user dialog boxes in SUD files.  DIAdem has a dialog editor utility that allows you to custom design your own SUD file or choose from a number of our commonly used templates. 

This EPD has three files.  One is a VB script, one is an SUD file, and one is a script library.  The script library contains a single function, Subroutine, which takes a string as an input parameter to display in a message box. The script library is included in both the VB script and the SUD file so that the Subroutine can be used in both. The VB script loads the SUD file and displays it.  It has three different checkboxes.  On the “value change” event for each checkbox, a DIAdem global variable, L1, is set to a different value. Then the Subroutine function is called from the script library, and the dialog is closed.  The VB script subsequently has an if-else case structure that determines what the value of L1 is and passes a different string to the same Subroutine function.

To run the example, just run the VB script through DIAdem’s script editor.

*Note:  In order for the example program to work, the SUD and VB script file can be located anywhere but must be in the same folder.

 

Requirements


Filename: user_decision_making_diadem.zip

Software Requirements


Application Software: DIAdem Development System 10.0
Language(s): VB Script

 
0 ratings | 0.00 out of 5
Print

Reader Comments | Submit a comment »

 

Legal
This example program (this "program") was developed by a National Instruments ("NI") Applications Engineer. Although technical support of this program may be made available by National Instruments, this program may not be completely tested and verified, and NI does not guarantee its quality in any way or that NI will continue to support this program with each new revision of related products and drivers. THIS EXAMPLE PROGRAM IS PROVIDED "AS IS" WITHOUT WARRANTY OF ANY KIND AND SUBJECT TO CERTAIN RESTRICTIONS AS MORE SPECIFICALLY SET FORTH IN NI.COM'S TERMS OF USE (http://ni.com/legal/termsofuse/unitedstates/us/).