NI-DAQmx .NET Framework 4.0 API Reference

Content Type
Programming Language
Current manual
Table of Contents

DaqSystem.SaveTaskAs Method (Task, String)

DaqSystem.SaveTaskAs Method (Task, String)

DaqSystemSaveTaskAs Method (Task, String)

Saves the task and any local channels it contains to Measurement Automation Explorer (MAX) under the specified name.

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

Syntax

public void SaveTaskAs(
	Task task,
	string persistedName
)
Public Sub SaveTaskAs ( 
	task As Task,
	persistedName As String
)

Parameters

task
Type: NationalInstruments.DAQmxTask
The task instance to save.
persistedName
Type: SystemString
The name to use for the saved task.

Exceptions

ExceptionCondition
DaqExceptionThe NI-DAQmx driver returned an error.

Remarks

This method sets the Default option for the saved task and uses an empty string for the task Author. You can specify your own options and author value by using the SaveTaskAs(Task, String, String, SaveOptions) overload.

You cannot view programmatically saved tasks in the DAQ Assistant for versions of NI-DAQ earlier than 7.4. To view a programmatically saved task in an earlier version of NI-DAQ, first use the DAQ Assistant in NI-DAQ 7.4 or later to save the task.

Visit the DAQmx Professional Developer Tools Web site for more information and examples of programmatically saving tasks.

See Also

Was this information helpful?