NI-DAQmx .NET Framework 4.0 API Reference

Content Type
Programming Language
Current manual
Table of Contents
Product DocumentationNI-DAQmx .NET Framework 4.0 API ReferenceAnalogSingleChannelWriter.WriteMultiSample MethodCurrent page
Table of Contents

AnalogSingleChannelWriter.WriteMultiSample Method

AnalogSingleChannelWriter.WriteMultiSample Method

AnalogSingleChannelWriterWriteMultiSample Method

Writes one or more floating-point samples to a single AOChannel in a task.

Namespace:  NationalInstruments.DAQmx
Assembly:  NationalInstruments.DAQmx (in NationalInstruments.DAQmx.dll) Version: 20.7.40.49302

Syntax

public void WriteMultiSample(
	bool autoStart,
	double[] data
)
Public Sub WriteMultiSample ( 
	autoStart As Boolean,
	data As Double()
)

Parameters

autoStart
Type: SystemBoolean
If set to this method automatically calls Start if you do not explicitly call it. You cannot set this parameter to if you have installed events on the task.
data
Type: SystemDouble
A 1D array of samples to write to the task. Each element of the array corresponds to a sample to write to the channel. The order of the channels in the array corresponds to the order in which you add the channels to the task.

Exceptions

ExceptionCondition
DaqExceptionThe NI-DAQmx driver returned an error.
IndexOutOfRangeExceptiondata has a non-zero lower bound.

Remarks

NI-DAQmx scales the generated data to the units of the measurement, including any custom scaling you apply to the channel. You specify these units with the create channel methods or the DAQ Assistant.

If the task uses on-demand timing, this method returns only after the device generates all samples. If the task uses any timing type other than on-demand, this method returns immediately and does not wait for the device to generate all samples. Your application must call the WaitUntilDone method to block until the device has generated all samples.

NI-DAQmx read and write methods time out after the amount of time specified by the Timeout property on the task you are reading from or writing to.

See Also

Was this information helpful?