---
id: object/codeunit/5467
type: object
title: Codeunit 5467 "PDF Document Management"
summary: Codeunit 5467 "PDF Document Management" in Base Application (Microsoft.EServices.EDocument). 4 public procedures. Present since at least BC23, still in BC30, changed in BC24-25, BC28.
tier: official
language: en
tags:
  - codeunit
  - base application
versions:
  introduced: null
  last_changed: "28"
  deprecated: null
review:
  state: derived
  by: null
  at: null
  flags: []
generated:
  at: "2026-10-11T00:31:51.816Z"
  pipeline: 0.2.0
  prompts: {}
  input_hash: ee7c22e8df5a040e319d11f05b48101d6e8c9dc957b92da0d6b66c49e91117ba
evidence:
  - kind: code
    url: https://github.com/microsoft/BCApps/blob/ea08af5ef2d6a9b5c5af4a029288abbe2c883220/src/Layers/W1/BaseApp/eServices/EDocument/PDFDocumentManagement.Codeunit.al
    title: src/Layers/W1/BaseApp/eServices/EDocument/PDFDocumentManagement.Codeunit.al (releases/29.x)
    date: null
    commit: ea08af5ef2d6a9b5c5af4a029288abbe2c883220
    t: null
    quote: null
links:
  learn: []
  objects: []
  features: []
  topics: []
  localizations: []
  videos: []
  posts: []
  guidelines: []
object_type: codeunit
object_id: 5467
name: PDF Document Management
namespace: Microsoft.EServices.EDocument
app: Base Application
extends: null
first_version: "23"
last_version: "30"
present_in:
  - "23"
  - "24"
  - "25"
  - "26"
  - "27"
  - "28"
  - "29"
  - "30"
changed_in:
  - "24"
  - "25"
  - "28"
source_major: "29"
obsolete: null
countries: []
ms_search_form_ids: []
counts:
  fields: 0
  procedures: 4
  events: 0
  subscribers: 0
relations:
  out: 0
  referenced_by: 0
  pages: 0
  extended_by: 0
  event_subscribers: 0
  calls: 5
  called_by: 42
  implements: 0
---

# Codeunit 5467 "PDF Document Management"

> Codeunit 5467 "PDF Document Management" in Base Application (Microsoft.EServices.EDocument). 4 public procedures. Present since at least BC23, still in BC30, changed in BC24-25, BC28.

Base Application · Microsoft.EServices.EDocument · BC23-30 · [source at ea08af5e](https://github.com/microsoft/BCApps/blob/ea08af5ef2d6a9b5c5af4a029288abbe2c883220/src/Layers/W1/BaseApp/eServices/EDocument/PDFDocumentManagement.Codeunit.al) · facts from BC29

## Procedures

- `GeneratePdf(DocumentId: Guid; var TempAttachmentEntityBuffer: Record "Attachment Entity Buffer" temporary): Boolean`
- `GeneratePdfBlobWithDocumentType(ParentId: Guid; DocumentId: Guid; DocumentType: Enum "Attachment Entity Buffer Document Type"; var TempAttachmentEntityBuffer: Record "Attachment Entity Buffer" temporary): Boolean`
- `GeneratePdfBlobWithDocumentType(DocumentId: Guid; DocumentType: Enum "Attachment Entity Buffer Document Type"; var TempAttachmentEntityBuffer: Record "Attachment Entity Buffer" temporary): Boolean`
- `AddToTempAttachmentEntityBuffer(DocumentId: Guid; DocumentType: Enum "Attachment Entity Buffer Document Type"; TempBlob: Codeunit "Temp Blob"; Name: Text[250]; var TempAttachmentEntityBuffer: Record "Attachment Entity Buffer" temporary): Boolean` (internal): Inits and adds generated report to the buffer

## Triggers

OnRun

## Calls

From the extracted call graph of BC29 (graphify-al on the snapshot checkout): calls whose target is known from a declared type or an `Object::"Name"` argument. Interface dispatch and calls through events are not counted, so the list is not complete.

- [Codeunit 4100 "Temp Blob"](../codeunit/4100.md) (2 calls: `AddToTempAttachmentEntityBuffer → CreateInStream`, `AddToTempAttachmentEntityBuffer → HasValue`)
- [Codeunit 260 "Document-Mailing"](../codeunit/260.md) (1 call: `GeneratePdf → GetAttachmentFileName`)
- [Codeunit 5477 "Sales Invoice Aggregator"](../codeunit/5477.md) (1 call: `GeneratePdf → GetSalesInvoiceHeaderFromId`)
- [Codeunit 5508 "Graph Mgt - Sal. Cr. Memo Buf."](../codeunit/5508.md) (1 call: `GeneratePdf → GetSalesCrMemoHeaderFromId`)
- [Codeunit 5529 "Purch. Inv. Aggregator"](../codeunit/5529.md) (1 call: `GeneratePdf → GetPurchaseInvoiceHeaderFromId`)

## Called by

- [Codeunit 4999 "Return Shpt. PDF Doc.Handler"](../codeunit/4999.md) (1 call: `GeneratePdfBlobWithDocumentType → AddToTempAttachmentEntityBuffer`)
- [Codeunit 5001 "Bl. S. Order PDF Doc.Handler"](../codeunit/5001.md) (1 call: `GeneratePdfBlobWithDocumentType → AddToTempAttachmentEntityBuffer`)
- [Codeunit 5002 "Bl. P. Order PDF Doc.Handler"](../codeunit/5002.md) (1 call: `GeneratePdfBlobWithDocumentType → AddToTempAttachmentEntityBuffer`)
- [Codeunit 5003 "S. Ret. Order PDF Doc.Handler"](../codeunit/5003.md) (1 call: `GeneratePdfBlobWithDocumentType → AddToTempAttachmentEntityBuffer`)
- [Codeunit 5004 "Sales Shipment PDF Doc.Handler"](../codeunit/5004.md) (1 call: `GeneratePdfBlobWithDocumentType → AddToTempAttachmentEntityBuffer`)
- [Codeunit 5006 "Purch. Quote PDF Doc.Handler"](../codeunit/5006.md) (1 call: `GeneratePdfBlobWithDocumentType → AddToTempAttachmentEntityBuffer`)
- [Codeunit 5007 "Purch. Rcpt. PDF Doc.Handler"](../codeunit/5007.md) (1 call: `GeneratePdfBlobWithDocumentType → AddToTempAttachmentEntityBuffer`)
- [Codeunit 5008 "Return Receipt PDF Doc.Handler"](../codeunit/5008.md) (1 call: `GeneratePdfBlobWithDocumentType → AddToTempAttachmentEntityBuffer`)
- [Codeunit 5009 "P. Ret. Order PDF Doc.Handler"](../codeunit/5009.md) (1 call: `GeneratePdfBlobWithDocumentType → AddToTempAttachmentEntityBuffer`)
- [Codeunit 5017 "Trans. Order PDF Doc.Handler"](../codeunit/5017.md) (1 call: `GeneratePdfBlobWithDocumentType → AddToTempAttachmentEntityBuffer`)
- [Codeunit 5018 "Trans. Shpt. PDF Doc.Handler"](../codeunit/5018.md) (1 call: `GeneratePdfBlobWithDocumentType → AddToTempAttachmentEntityBuffer`)
- [Codeunit 5019 "Trans. Rcpt. PDF Doc.Handler"](../codeunit/5019.md) (1 call: `GeneratePdfBlobWithDocumentType → AddToTempAttachmentEntityBuffer`)
- [Codeunit 5020 "S.Arch.Quote PDF Doc.Handler"](../codeunit/5020.md) (1 call: `GeneratePdfBlobWithDocumentType → AddToTempAttachmentEntityBuffer`)
- [Codeunit 5021 "S.Arch.Order PDF Doc.Handler"](../codeunit/5021.md) (1 call: `GeneratePdfBlobWithDocumentType → AddToTempAttachmentEntityBuffer`)
- [Codeunit 5022 "P.Arch.Quote PDF Doc.Handler"](../codeunit/5022.md) (1 call: `GeneratePdfBlobWithDocumentType → AddToTempAttachmentEntityBuffer`)
- [Codeunit 5023 "P.Arch.Order PDF Doc.Handler"](../codeunit/5023.md) (1 call: `GeneratePdfBlobWithDocumentType → AddToTempAttachmentEntityBuffer`)
- [Codeunit 5024 "S.Arch.Return PDF Doc.Handler"](../codeunit/5024.md) (1 call: `GeneratePdfBlobWithDocumentType → AddToTempAttachmentEntityBuffer`)
- [Codeunit 5025 "P.Arch.Return PDF Doc.Handler"](../codeunit/5025.md) (1 call: `GeneratePdfBlobWithDocumentType → AddToTempAttachmentEntityBuffer`)
- [Codeunit 5026 "Asm. Order PDF Doc.Handler"](../codeunit/5026.md) (1 call: `GeneratePdfBlobWithDocumentType → AddToTempAttachmentEntityBuffer`)
- [Codeunit 5027 "P.Asm. Order PDF Doc.Handler"](../codeunit/5027.md) (1 call: `GeneratePdfBlobWithDocumentType → AddToTempAttachmentEntityBuffer`)
- [Codeunit 5028 "S.Arch.Bl.Ord PDF Doc.Handler"](../codeunit/5028.md) (1 call: `GeneratePdfBlobWithDocumentType → AddToTempAttachmentEntityBuffer`)
- [Codeunit 5029 "P.Arch.Bl.Ord PDF Doc.Handler"](../codeunit/5029.md) (1 call: `GeneratePdfBlobWithDocumentType → AddToTempAttachmentEntityBuffer`)
- [Codeunit 5030 "Phys.Inv.Ord. PDF Doc.Handler"](../codeunit/5030.md) (1 call: `GeneratePdfBlobWithDocumentType → AddToTempAttachmentEntityBuffer`)
- [Codeunit 5031 "P.Phys.InvOrd PDF Doc.Handler"](../codeunit/5031.md) (1 call: `GeneratePdfBlobWithDocumentType → AddToTempAttachmentEntityBuffer`)
- [Codeunit 5032 "Phys.Inv.Rec. PDF Doc.Handler"](../codeunit/5032.md) (1 call: `GeneratePdfBlobWithDocumentType → AddToTempAttachmentEntityBuffer`)
- [Codeunit 5033 "P.Phys.InvRec PDF Doc.Handler"](../codeunit/5033.md) (1 call: `GeneratePdfBlobWithDocumentType → AddToTempAttachmentEntityBuffer`)
- [Codeunit 5034 "Inv. Shpt. PDF Doc.Handler"](../codeunit/5034.md) (1 call: `GeneratePdfBlobWithDocumentType → AddToTempAttachmentEntityBuffer`)
- [Codeunit 5035 "Inv. Rcpt. PDF Doc.Handler"](../codeunit/5035.md) (1 call: `GeneratePdfBlobWithDocumentType → AddToTempAttachmentEntityBuffer`)
- [Codeunit 5036 "P.Inv. Shpt. PDF Doc.Handler"](../codeunit/5036.md) (1 call: `GeneratePdfBlobWithDocumentType → AddToTempAttachmentEntityBuffer`)
- [Codeunit 5037 "P.Inv. Rcpt. PDF Doc.Handler"](../codeunit/5037.md) (1 call: `GeneratePdfBlobWithDocumentType → AddToTempAttachmentEntityBuffer`)
- [Codeunit 5038 "P.Direct Trans PDF Doc.Handler"](../codeunit/5038.md) (1 call: `GeneratePdfBlobWithDocumentType → AddToTempAttachmentEntityBuffer`)
- [Codeunit 5441 "Sales Order PDF Doc.Handler"](../codeunit/5441.md) (1 call: `GeneratePdfBlobWithDocumentType → AddToTempAttachmentEntityBuffer`)
- [Codeunit 5444 "Sales Cr.Memo PDF Doc.Handler"](../codeunit/5444.md) (1 call: `GeneratePdfBlobWithDocumentType → AddToTempAttachmentEntityBuffer`)
- [Codeunit 5445 "Cust. St. PDF Doc.Handler"](../codeunit/5445.md) (1 call: `GeneratePdfBlobWithDocumentType → AddToTempAttachmentEntityBuffer`)
- [Codeunit 5446 "Purch. Invoice PDF Doc.Handler"](../codeunit/5446.md) (1 call: `GeneratePdfBlobWithDocumentType → AddToTempAttachmentEntityBuffer`)
- [Codeunit 5447 "Purch. Cr.Memo PDF Doc.Handler"](../codeunit/5447.md) (1 call: `GeneratePdfBlobWithDocumentType → AddToTempAttachmentEntityBuffer`)
- [Codeunit 5449 "Sales Quote PDF Doc.Handler"](../codeunit/5449.md) (1 call: `GeneratePdfBlobWithDocumentType → AddToTempAttachmentEntityBuffer`)
- [Codeunit 5450 "Sales Invoice PDF Doc.Handler"](../codeunit/5450.md) (1 call: `GeneratePdfBlobWithDocumentType → AddToTempAttachmentEntityBuffer`)
- [Codeunit 5453 "Purch. Order PDF Doc.Handler"](../codeunit/5453.md) (1 call: `GeneratePdfBlobWithDocumentType → AddToTempAttachmentEntityBuffer`)
- [Codeunit 5454 "Project PDF Doc.Handler"](../codeunit/5454.md) (1 call: `GeneratePdfBlobWithDocumentType → AddToTempAttachmentEntityBuffer`)
- [Page 20057 "APIV1 - PDF Document"](../page/20057.md) (1 call: `OnFindRecord → GeneratePdf`)
- [Page 30056 "APIV2 - PDF Document"](../page/30056.md) (1 call: `OnFindRecord → GeneratePdfBlobWithDocumentType`)

## Across versions

- Present in: BC23-30
- Changed (declaration) in: BC24-25, BC28

Source: AL metadata extracted from the code (names, ids, signatures, properties); no code bodies (D10).

## Ask your agent

Procedure bodies are not stored here (D10). The call sections above are our own, per object, from the BC29 call graph. For a procedure body or the calls of one procedure, ask bc-code-atlas (external, by Stefan Maron, MIT; default corpus w1-28), which the bc-observatory plugin connects: `bcatlas_resolve_node(object_type: "codeunit", object_name: "PDF Document Management")`, then `bcatlas_get_procedure_body` or `bcatlas_get_neighbors` on the returned id.
