| Keysight.Visa Namespace > VisaSession Class : UnlockResource Method |
'DeclarationPublic Sub UnlockResource()
'UsageDim instance As VisaSession instance.UnlockResource()
public void UnlockResource()
public: void UnlockResource();
For each session, LockResource and UnlockResource share an internal lock count, which is initialized to 0. Each successful call to LockResource on the same session (and for the same lock type) increases the lock count. When a session locks the resource a multiple number of times, it is necessary to invoke the UnlockResource method an equal number of times in order to unlock the resource. That is, the lock count increments for each call to LockResource, and decrements for each call to UnlockResource. A resource is actually unlocked only when the lock count is 0.
It is possible to obtain both shared and exclusive locks on the same resource, in that order. In such cases, this method decrements the exclusive lock count first, and then the shared lock count.
Current with Keysight IO Libraries Suite 18