Attributes and Attribute Functions
- Updated2023-09-20
- 1 minute(s) read
Attributes and Attribute Functions
Attributes—which are also called properties in LabVIEW—serve as a base for parameters. For example, the Minimum Number Points parameter in the Configure Horizontal Timing function is actually built on the Horizontal Minimum Number of Points, Horizontal Minimum Sample Rate, Horizontal Number of Records, and Horizontal Record Reference Position attributes. Because attributes and attribute functions require additional code and include limited error checking, avoid using attributes except in the following cases:
- Use attributes if NI-SCOPE does not have a high-level function that sets an attribute that you need.
- Use attributes if you need to change one variable at a time. Attributes allow you to change one variable at a time, whereas functions and parameters do not. Because NI-SCOPE efficiently caches previous settings, there is no performance penalty if you use a function when only one variable is changed at a time.
Attributes are used frequently when making waveform measurements.
Accessing Attributes
In LabVIEW, you can find attributes in the NI-SCOPE property node by dropping the property node from the NI-SCOPE palette onto your block diagram.
In C and Visual Basic, you can access attributes with the Set Attribute and Get Attribute functions.