NI-DAQmx .NET Framework 4.5 API Reference

Content Type
Programming Language
Current manual
Table of Contents
Product DocumentationNI-DAQmx .NET Framework 4.5 API Reference...AnalogUnscaledWriter MethodsBeginWrite Method AnalogUnscaledWriter.BeginWrite Method (Boolean, Int16[,], AsyncCallback, Object)Current page
Table of Contents

AnalogUnscaledWriter.BeginWrite Method (Boolean, Int16[,], AsyncCallback, Object)

AnalogUnscaledWriter.BeginWrite Method (Boolean, Int16[,], AsyncCallback, Object)

AnalogUnscaledWriterBeginWrite Method (Boolean, Int16, AsyncCallback, Object)

Begins an asynchronous write of one or more unscaled 16-bit integer samples to one or more AOChannel objects in a task.

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

Syntax

public IAsyncResult BeginWrite(
	bool autoStart,
	short[,] data,
	AsyncCallback callback,
	Object state
)
Public Function BeginWrite ( 
	autoStart As Boolean,
	data As Short(,),
	callback As AsyncCallback,
	state As Object
) As IAsyncResult

Parameters

autoStart
Type: SystemBoolean
If set to this method automatically calls Start if you do not explicitly call it.
data
Type: SystemInt16
A 2D array of samples to write to the task. Each element in the first dimension of the array corresponds to a channel in the task. Each element in the second dimension of the array corresponds to a sample to write to each channel. The order of the channels in the array corresponds to the order in which you add the channels to the task. The order of the lines in the array corresponds to the order in which you add the lines to the channel.
callback
Type: SystemAsyncCallback
An optional asynchronous callback that is called when the write is complete. Specify if you do not want a callback when the write is complete.
state
Type: SystemObject
A user-provided object that distinguishes this asynchronous write request from other requests. Use this parameter to provide information to the callback. Specify if you do not need to pass any additional information to the callback.

Return Value

Type: IAsyncResult
An IAsyncResult that represents the asynchronous call.

Remarks

Pass the returned IAsyncResult to EndWrite(IAsyncResult) to get any exceptions that occurred during the asynchronous write or to wait for the write to complete.

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.

Note Note
Refer to Asynchronous Reads and Writes for additional information.

See Also

In This Section
Was this information helpful?