EasyUA Reference
TryEnter Method
See Also  Send Feedback
Opc.Ua.Core.Net4 Assembly > Opc.Ua Namespace > SafeLock Class : TryEnter Method

timeout
The number of milliseconds to wait.

Glossary Item Box

Attempts to acquire the lock.

Syntax

Visual Basic (Usage)Copy Code
Dim instance As SafeLock
Dim timeout As Integer
Dim value As Boolean
 
value = instance.TryEnter(timeout)
C# 
public bool TryEnter( 
   int timeout
)

Parameters

timeout
The number of milliseconds to wait.

Return Value

True if the lock was acquired.

Exceptions

ExceptionDescription
System.InvalidOperationExceptionThrown if the lock state is inconsistent.

Requirements

Target Platforms: Windows 7/8/10, Windows Server 2003/2008/2012/2015, .NET4.x

See Also

Copyright © 2018 Advosol Inc. All Rights Reserved.