DocumentChangeState Method |
Changes the document state to the specified new state
Namespace:
Aloe.EnterpriseOne.Model.General
Assembly:
Aloe.EnterpriseOne.Model (in Aloe.EnterpriseOne.Model.dll) Version: 20.1.3.5
Syntaxpublic void ChangeState(
DocumentState newState,
DocumentTypeUserStatus userStatus = null
)
Public Sub ChangeState (
newState As DocumentState,
Optional userStatus As DocumentTypeUserStatus = Nothing
)
public:
void ChangeState(
DocumentState^ newState,
DocumentTypeUserStatus^ userStatus = nullptr
)
member ChangeState :
newState : DocumentState *
?userStatus : DocumentTypeUserStatus
(* Defaults:
let _userStatus = defaultArg userStatus null
*)
-> unit
Parameters
- newState
- Type: Aloe.EnterpriseOne.Model.GeneralDocumentState
The desired new state of the document - userStatus (Optional)
- Type: Aloe.EnterpriseOne.Model.GeneralDocumentTypeUserStatus
The desired new user status of the document. Can be null.
Remarks
The process of changing the document state is very labor intensive and includes
validation, generation of sub-documents and some other document-specific tasks.
The state changing process might be very time-consuming, usually ranging
from 500 to 5000 milliseconds.
Document states usually can only be advanced to higher states, but there are
exceptions from this rule. Database settings and configuration options might affect
the allowed state changes.
Numerous kinds of document-specific and generic exceptions can be thrown during the
process.
See Also