# EXT\_Document\_Cancel​

> MSS documentation · https://doc.sysdevmobile.com/mss/extensibility/functions-kalipso-to-mss/document/ext_document_cancel
>
> EXT_Document_Cancel anula um documento (exercício, tipo, série, número), com o motivo indicado ou escolhido na janela de motivos.

Function to ask MSS to cancel a document.

_Input parameters_:

* inDocumentExercise – Exercise of the document;
* inDocumentType – Type of the document;
* inDocumentSeries – Series of the document;
* inDocumentNumber – Number of the document;
* inCancelCode – If not empty MSS will cancel the document with this motive code, otherwise will open MSS cancel motive selection window;

_Output parameters_:

* outResultCode – Return code: 0 – Done / < 0 User canceled selection or error occurred;
