共用方式為


SPJobDefinition.LockType Property

Gets the lock type for the job definition.

Namespace:  Microsoft.SharePoint.Administration
Assembly:  Microsoft.SharePoint (in Microsoft.SharePoint.dll)

Syntax

Public ReadOnly Property LockType As SPJobLockType
    Get

Dim instance As SPJobDefinition
Dim value As SPJobLockType

value = instance.LockType
public SPJobLockType LockType { get; }

Property Value

Type: Microsoft.SharePoint.Administration.SPJobLockType
An SPJobLockType value.

Remarks

Use the LockType property to prevent the same job from simultaneously running on multiple machines and processing the same data.

See Also

Reference

SPJobDefinition Class

SPJobDefinition Members

Microsoft.SharePoint.Administration Namespace