Click or drag to resize
DocumentLockExtensionsLockAsync Method (Document, ActionException, String, Int32)
Locks this instance and returns a DocumentLock object which can be used to unlock this document later.

Namespace: DocuWare.Platform.ServerClient
Assembly: DocuWare.Platform.ServerClient (in DocuWare.Platform.ServerClient.dll) Version: Version 6.7 [UNOFFICIAL BUILD]
Syntax
C#
public static Task<DocumentLock> LockAsync(
	this Document document,
	Action<Exception> onError,
	string operation,
	int lockIntervalInSeconds = 60
)

Parameters

document
Type: DocuWare.Platform.ServerClientDocument
The document.
onError
Type: SystemActionException
Action which is called on error.
operation
Type: SystemString
A client identifier associated with lock operation.
lockIntervalInSeconds (Optional)
Type: SystemInt32

Return Value

Type: TaskDocumentLock
A DocumentLock which can be used to unlock this document later. Optional parameter to specify interval to specify how often to renew the lock.

Usage Note

In Visual Basic and C#, you can call this method as an instance method on any object of type Document. When you use instance method syntax to call this method, omit the first parameter. For more information, see Extension Methods (Visual Basic) or Extension Methods (C# Programming Guide).
See Also