Gets the System.Runtime.InteropServices.SafeHandle to the NIDCPower instrument session.

Syntax

Namespace: NationalInstruments.ModularInstruments.NIDCPower

public SafeHandle GetInstrumentHandle()

Remarks

Using the System.Runtime.InteropServices.SafeHandle, you can get the System.IntPtr to the session; however, there are risks involved with using the System.IntPtr. It is difficult to know the state of the handle, and the handle could be recycled while you are using it. For more information, refer to System.Runtime.InteropServices.SafeHandle.DangerousGetHandle.

Returns

The System.Runtime.InteropServices.SafeHandle to the NIDCPower instrument session.

Exceptions

TypeDescription
System.ObjectDisposedException

GetInstrumentHandle was called after the associated NIDCPower object was disposed.