SetDeviceName


Function

Set the device name.

Format

Ret = SetDeviceName (DeviceName)

Parameters

DeviceName [ VB.NET : String] [ C++ : BSTR ] [ C# : string]

Specify the device name.

Return Value

Ret [ VB.NET : Integer ] [ C++ : long ] [ C# : int ]

Return Value

Description

0

Normal completed

10006

Cannot execute because the device is in operation.

20000

Device name is outside the settable range.

The others (See also: Error Code List)

Remarks

When setting the device name, please set a device that is supported by C-WaveformGenerator (with analog output function).
Use the specified function until you select another device or drop the application.
When changing from a device with 4 channels to a device with 2 channels, the number of channels becomes 2.
If the device is in operation, this function cannot be performed.

Example

Set the device name "AIO000".

VB.NET

Dim Ret As Long

Ret = c_fgen.SetDeviceName("AIO000")

 

C++

long Ret;

ICWaveformGeneratorPtr c_fgen;

Ret = c_fgen->SetDeviceName(L"AIO000");

 

C#

int Ret;

Ret = c_fgen.SetDeviceName("AIO000");

 

See Also

GetDeviceName