Attempts to acquire a synchronization lock on this instance of the driver and specifies the maximum amount of time to wait to acquire the lock.

Syntax

Namespace: NationalInstruments.ModularInstruments.NIDCPower

public DCPowerDriverLock Lock(Ivi.Driver.PrecisionTimeSpan maximumTime)

Parameters

NameTypeDescription
maximumTimeIvi.Driver.PrecisionTimeSpan

Specifies the maximum amount of time to wait to acquire the lock.

Returns

Returns an object of type Ivi.Driver.IIviDriverLock as a reference to the acquired lock.

Exceptions

TypeDescription
System.ObjectDisposedException

The Lock(PrecisionTimeSpan) method was called after the associated NIDCPower object was disposed.