TableScale Class

NI-DAQmx 17.1 .NET Class Library Help

Edition Date: June 2017

Part Number: 370473J-01

»View Product Info
Download Help (Windows Only)

Members Example See Also


Encapsulates a custom scale that maps an array of prescaled values to an array of corresponding scaled values, with all other values scaled proportionally.

Namespace: NationalInstruments.DAQmx

Assembly: NationalInstruments.DAQmx (in NationalInstruments.DAQmx.dll) Version: 17.1.40.99

Syntax

Visual Basic (Declaration)
Public Class TableScale _
	Inherits Scale

C#
public class TableScale : Scale

Remarks

Note:Example applications are located in the Public Documents\National Instruments\NI-DAQ\Examples\DotNET4.x directory or in the Start menu at National InstrumentsNI-DAQmxNI-DAQmx Examples.

Examples

The following example explains how to update the PreScaledValues property that returns an array:

CopyVB.NET
Dim preScaledValues As Double() = New Double() {0.11, 0.12, 0.13}
Dim scaledValues As Double() = New Double() {1.1, 1.2, 1.3}
Dim tablescale As New TableScale("DAQmxTableScale", preScaledValues, scaledValues)

' To update the value at specific index in tablescale.PreScaledValues
' change the source array and assign it back to the property.
preScaledValues(0) = 0.1
tablescale.PreScaledValues = preScaledValues
CopyC#
double[] preScaledValues = new double[] { .11, .12, .13 };
double[] scaledValues = new double[] { 1.1, 1.2, 1.3 };
TableScale tablescale = new TableScale("DAQmxTableScale", preScaledValues, scaledValues);

// To update the value at specific index in tablescale.PreScaledValues
// change the source array and assign it back to the property.
preScaledValues[0] = 0.1;
tablescale.PreScaledValues = preScaledValues;

The following example explains how to update the ScaledValues property that returns an array:

CopyVB.NET
Dim preScaledValues As Double() = New Double() {0.11, 0.12, 0.13}
Dim scaledValues As Double() = New Double() {1.1, 1.2, 1.3}
Dim tablescale As New TableScale("DAQmxTableScale", preScaledValues, scaledValues)

' To update the value at specific index in tablescale.ScaledValues
' change the source array and assign it back to the property.
scaledValues(0) = 1.12
tablescale.ScaledValues = scaledValues
CopyC#
double[] preScaledValues = new double[] { .11, .12, .13 };
double[] scaledValues = new double[] { 1.1, 1.2, 1.3 };
TableScale tablescale = new TableScale("DAQmxTableScale", preScaledValues, scaledValues);

// To update the value at specific index in tablescale.ScaledValues
// change the source array and assign it back to the property.
scaledValues[0] = 1.12;
tablescale.ScaledValues = scaledValues;

Inheritance Hierarchy

System.Object
  System.MarshalByRefObject
    NationalInstruments.DAQmx.Scale
      NationalInstruments.DAQmx.TableScale

Thread Safety

All members of this type are safe for multithreaded operations.

See Also

Reference

TableScale Members

NationalInstruments.DAQmx Namespace

WAS THIS ARTICLE HELPFUL?

Not Helpful