DocumentObject.<Document name>.BeforeWrite

Syntax:

BeforeWrite(<Cancel>, <WriteMode>, <PostingMode>)

Parameters:

<Cancel>

Type: Boolean.
Write cancel flag. If the parameter value is set to True in the body of the handler procedure, writing is not performed and the exception is raised.
Default value: False.

<WriteMode>

Type: DocumentWriteMode.
A current document write mode is transferred in this parameter. Use it to specify a write mode in the body of a procedure. Changing this parameter enables the user to change the write mode.

<PostingMode>

Type: DocumentPostingMode.
A current posting mode is passed to this parameter.
Changing this parameter enables the user to change the posting mode.

Description:

Occurs before object writing. A handler procedure is called after the start of writing transaction but before the document writing is really starts.

    

1C:Enterprise Developer's Community