UserLockAccount Method (ConnectionId, SessionId, Int32, Boolean) Content Studio 5.7 SDK
Content Studio Web Content Management System

[This is preliminary documentation and is subject to change.]

Locks or unlocks a registered user account.

Namespace: ContentStudio.Security
Assembly: CSServer5 (in CSServer5.dll) Version: 5.7.5016.0 (5.7.5016.0)
Syntax

public void LockAccount(
	ConnectionId connectionId,
	SessionId sessionId,
	int userId,
	bool shouldLock
)

Parameters

connectionId
Type: ContentStudioConnectionId
A value that identifies the web site
sessionId
Type: ContentStudio.SecuritySessionId
A value that identifies the user's session. This value usually originates from a call to OpenSession(ConnectionId).
userId
Type: SystemInt32
The Content Studio identifier of the user to lock
shouldLock
Type: SystemBoolean
Set to false to unlock a locked user account, true to lock it.
Exceptions

ExceptionCondition
CSExceptionA business rule was violated in the underlying Content Studio database
SqlExceptionAn error occurred when executing the command against the Content Studio database
Remarks

Note that this only affects Content Studio. A locked account will not be able to do anything in Content Studio and the lock takes immediate effect. A locked account can still browse the site if anonymous access is supported.
See Also

Reference