Unlock Feature

Unlocks the access to locked resources by Block Resource and Block Semaphore commands.

Command availability: IBM RPA SaaS and IBM RPA on premises

Script syntax

IBM RPA's proprietary script language has a syntax similar to other programming languages. The script syntax defines the command's syntax in the script file. You can work with this syntax in IBM RPA Studio's Script mode.

release

Dependencies

Example

The following code example demonstrates how to unlock a resource.

defVar --name successfullyEnteringLock --type Boolean
defVar --name lockName --type String
// Assigns the lock name to 'LogMessageLock'
setVar --name "${lockName}" --value LogMessageLock
// Blocks the access to the resource for the first time. It create a global lock to this resource.
waitLock --global  --name "${lockName}" --timeout "00:00:52" successfullyEnteringLock=success
	// Logs the success to enter the lock.
	logMessage --message "Success to enter the \"${lockName}\" lock: ${successfullyEnteringLock}" --type "Info"
	// Unlocks the 'LogMessageLock' lock, so it can be used another time.
release