Skip to content

Codeunit WSB_DCAPDFArchive

Exposes procedures related to the PDF archive feature.

Properties

Name Value
Access Public

Methods

wgFncGetCategoryCode(Report Selections):Code[20]

Get a category code for a report selection record.

Parameters

Type Name Description
Record "Report Selections" temporary pRecTempReportSelections The report selection record.

Returns

Type Description
Code[20] The code of the file category.

wgFncSetArchiveMethodFromDefault(Report Selections@)

Sets the archive method to use from the setup value on a report selection record.

Parameters

Type Name Description
Record "Report Selections" vRecReportSelections The report selection record to set the default on.

wgFncSetPDFArchiveScenarioDefaults(Boolean)

Sets up the PDF Archive scenario defaults.

Parameters

Type Name Description
Boolean pReset Whether to reset the defaults.

wlEvpOnAfterAttachDocumentAsPdfToDocumentArchive(RecordRef, Report Selections@, Code[20], Codeunit::System#Utilities#Temp Blob, Enum::WSB_DCAPDFArchiveScenario, Code[20], Boolean@)

Raised after the document PDF file has been uploaded to the remote via the PDF Archive feature of Document Archive.

Parameters

Type Name Description
RecordRef pRecRef The source record.
Record "Report Selections" temporary vRecTempReportSelections Temporary recordset of Report Selection
Code[20] pDocumentNo The document no.
Codeunit "Temp Blob" pCduTempBlob The file that will be uploaded.
Enum "WSB_DCAPDFArchiveScenario" pPDFArchiveScenario Specifies the PDF Archive scenario.
Code[20] pCategoryCode The category code of the selected Report Selection.
Boolean vAttached True if the document is succesfuly uploaded.

wlEvpOnAfterGetPDFArchiveDocumentName(Enum::WSB_DCAPDFArchiveDocNameMethod, Integer, RecordRef, Text@)

Allows to hook into getting a document name for a PDF archive file.

Parameters

Type Name Description
Enum "WSB_DCAPDFArchiveDocNameMethod" pPDFArchiveDocumentNamingMethod The naming method used.
Integer pReportID The ID of the report object used to generate the PDF.
RecordRef pRecRef The source record.
Text vDocumentNameTxt The document name text.

wlEvpOnAfterGetPDFArchiveScenarioFromDocumentPayload(Text, JsonObject, Enum::WSB_DCAPDFArchiveScenario@, Boolean@)

Allows to hook into retrieving the PDF Archive scenario from the document payload (from the ReportManagement.OnDocumentReady event).

Parameters

Type Name Description
Text pIntentAsText The intent as text.
JsonObject pDocumentPayload The full document payload.
Enum "WSB_DCAPDFArchiveScenario" vPDFArchiveScenario The result PDF archive scenario.
Boolean vArchiveScenarioSupported Whether the archive scenario is supported.

wlEvpOnAfterUploadDMQEmailAttachmentPdfToDocumentArchive(Integer, RecordRef, Report Selections@, Enum::WSB_DCAPDFArchiveScenario, Code[20], Codeunit::System#Utilities#Temp Blob, Boolean)

Raised after the document PDF file from an email sent from Document Mail Queue has been uploaded to the remote via the PDF Archive feature of Document Archive.

Parameters

Type Name Description
Integer pQueueEntryNo The Document Mail Queue Entry No.
RecordRef pRecRef The source record.
Record "Report Selections" temporary vRecTempReportSelections Temporary recordset of Report Selection.
Enum "WSB_DCAPDFArchiveScenario" pPDFArchiveScenario Specifies the PDF Archive scenario.
Code[20] pDocumentNo The document no.
Codeunit "Temp Blob" pCduTempBlob The file that will be uploaded.
Boolean pAttached True if the document is succesfuly uploaded.

wlEvpOnBeforeGetPDFArchiveFileName(Integer, RecordRef, Code[20], Text@, Boolean@)

Allows to hook into getting a file name for a PDF archive file.

Parameters

Type Name Description
Integer pReportID The ID of the report object used to generate the PDF file.
RecordRef pRecRef The source record.
Code[20] pDocumentNo The document no.
Text vFileName The resulting file name.
Boolean vIsHandled Set this to true if your extension handles getting a PDF file name.