BaseCollection.SyncRoot Property

 
System_CAPS_noteNote

The .NET API Reference documentation has a new home. Visit the .NET API Browser on docs.microsoft.com to see the new experience.

Gets an object that can be used to synchronize access to the BaseCollection.

Namespace:   System.Windows.Forms
Assembly:  System.Windows.Forms (in System.Windows.Forms.dll)

[BrowsableAttribute(false)]
public object SyncRoot { get; }

Property Value

Type: System.Object

An object that can be used to synchronize the BaseCollection.

If, as is the case with the BaseCollection, the IsSynchronized property returns false, then the SyncRoot property returns an object that can be used with the C# lock keyword.

.NET Framework
Available since 1.1
Return to top
Show: