CNiIviUtility::LockSession

Measurement Studio IVI

Class
CNiIviUtility::
LockSession()
Base ClassesFunctionsGo to hierarchy chart    Prev page: ErrorQueryNext page: Reset    
Public Function Declared in:
NiIviDriver.h

'Declaration' icon -- Shortcut to top of page. Declaration

inline void LockSession();

'Description' icon -- Shortcut to top of page. Description

Gets a multithread lock on the instrument session. After your call to LockSession returns successfully, no other threads can access the instrument session until you call UnlockSession.

Use LockSession and UnlockSession around a sequence of calls to instrument driver functions if you require that the instrument retain its settings through the end of the sequence.

You can safely make multiple calls to LockSession within the same thread. However, to completely unlock the session, you must balance each call to LockSession with a call to UnlockSession.

'See Also' icon -- Shortcut to top of page. See Also