WorkflowGetUserAction Method (ConnectionId, SessionId, DocumentId, CategoryId, Boolean) Content Studio 5.7 SDK
Content Studio Web Content Management System

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

Returns information about a document's workflow status and what actions the caller can perform.

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

public string GetUserAction(
	ConnectionId connectionId,
	SessionId sessionId,
	DocumentId documentId,
	CategoryId categoryId,
	bool returnStepXml
)

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).
documentId
Type: ContentStudio.DocumentDocumentId
The id of a document to get user actions for. If the document is about to be create this parameter can be set to zero and the system looks at the CategoryID parameter instead. In that case CategoryID must be supplied.
categoryId
Type: ContentStudio.DocumentCategoryId
The id of a category that the document that are to be created belongs to. If DocumentID is supplied the system ignores this parameter. In that case DocumentID must be supplied.
returnStepXml
Type: SystemBoolean
Indicates whether to return the step information along with the workflow xml

Return Value

Type: String
Xml, with the following syntax
<root>
  <usesworkflow>Boolean value</usesworkflow>
  <status>0</status>
  <statustext>Success</statustext>
  <accessmask>Integer value</accessmask>
  <workflow>
  <!-- If workflow is in use xml at this point contains the action information -->
  </workflow>
</root>
ElementMeaning
root/usesworkflowNumeric boolean, 1 if workflow is in use, 0 otherwise.
root/statusInteger, always 0 which indicates a successful call.
root/statustextString, always "Success" which indicates a successful call.
root/accessmaskInteger flags, a combination of the WorkflowCallerPermissions flag values indicating the permission of the caller.
root/workflowThis is the root node for the returned workflow definitions xml that can be used to determine the actual actions that can be performed. This element is empty when no workflow is in use.
Exceptions

ExceptionCondition
InvalidOperationExceptionBoth the DocumentID and the CategoryID arguments cannot be zero.
CSExceptionA workflow rule was violated.
XmlExceptionInvalid xml was supplied internally.
See Also

Reference