Chapter 3 Developing Your Application
© National Instruments Corp. 3-23 NI-488.2 User Manual for Windows
Direct Entry with Visual Basic
See the Visual Basic section, earlier in this chapter, for information on calling the NI-488
functions with Visual Basic.
Include the file niglobal.bas in your application project file. You must create a file
(for example, dllfunc.bas) that contains the direct entry prototypes of the functions
used in your application program. Include the direct entry file in your application project
file. Refer to the NI-488.2 Function Reference Manual for DOS/Windows for the Visual
Basic direct entry syntax for NI-488 and NI-488.2 functions.
If you are using Microsoft Visual Basic 1.0, you must edit niglobal.bas to define the
constants true and false as follows:
global const true = -1
global const false = 0
In Microsoft Visual Basic 2.0 and higher, true and false are reserved words;
therefore, these constants are no longer defined in niglobal.bas.
After you have written your Visual Basic application, choose the Start option from the
Run menu to execute your program.