---
id: object/page/43
type: object
title: Page 43 "Sales Invoice"
summary: Page 43 "Sales Invoice" in Base Application (Microsoft.Sales.Document). 5 public procedures, 11 events. Present since at least BC23, still in BC30, changed in BC25-27, BC29.
tier: official
language: en
tags:
  - page
  - base application
versions:
  introduced: null
  last_changed: "29"
  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: c5ca61f52adf7e0108c31a79f44f4c9c2d3affeb91a763797d03024f1020ae82
evidence:
  - kind: code
    url: https://github.com/microsoft/BCApps/blob/ea08af5ef2d6a9b5c5af4a029288abbe2c883220/src/Layers/W1/BaseApp/Sales/Document/SalesInvoice.Page.al
    title: src/Layers/W1/BaseApp/Sales/Document/SalesInvoice.Page.al (releases/29.x)
    date: null
    commit: ea08af5ef2d6a9b5c5af4a029288abbe2c883220
    t: null
    quote: null
  - kind: learn
    url: https://learn.microsoft.com/dynamics365/business-central/finance-how-use-edocuments
    title: Use e-documents in sales
    date: null
    commit: null
    t: null
    quote: null
  - kind: learn
    url: https://learn.microsoft.com/dynamics365/business-central/LocalFunctionality/France/finance-sales-invoice-specifics
    title: Deliver sales invoices with French specifics
    date: null
    commit: null
    t: null
    quote: null
  - kind: learn
    url: https://learn.microsoft.com/dynamics365/business-central/sales-how-invoice-sales
    title: Invoice sales
    date: null
    commit: null
    t: null
    quote: null
  - kind: learn
    url: https://learn.microsoft.com/dynamics365/business-central/sales-how-register-new-customers
    title: Register new customers by creating a Customer Card
    date: null
    commit: null
    t: null
    quote: null
  - kind: learn
    url: https://learn.microsoft.com/dynamics365/business-central/value-chain-howto-sales
    title: Sustainability value chain in sales
    date: null
    commit: null
    t: null
    quote: null
links:
  learn:
    - https://learn.microsoft.com/dynamics365/business-central/finance-how-use-edocuments
    - https://learn.microsoft.com/dynamics365/business-central/LocalFunctionality/France/finance-sales-invoice-specifics
    - https://learn.microsoft.com/dynamics365/business-central/sales-how-invoice-sales
    - https://learn.microsoft.com/dynamics365/business-central/sales-how-register-new-customers
    - https://learn.microsoft.com/dynamics365/business-central/value-chain-howto-sales
  objects: []
  features: []
  topics:
    - topic/business-central/business-functionality/finance/set-up-and-use-e-documents
    - topic/business-central/business-functionality/sales
    - topic/business-central/business-functionality/set-up-business-central/set-up-sales
    - topic/business-central/business-functionality/sustainability-management/sustainability-value-chain
  localizations:
    - localization/it
    - localization/no
  videos: []
  posts: []
  guidelines: []
object_type: page
object_id: 43
name: Sales Invoice
namespace: Microsoft.Sales.Document
app: Base Application
extends: null
first_version: "23"
last_version: "30"
present_in:
  - "23"
  - "24"
  - "25"
  - "26"
  - "27"
  - "28"
  - "29"
  - "30"
changed_in:
  - "25"
  - "26"
  - "27"
  - "29"
source_major: "29"
obsolete: null
countries:
  - it
  - "no"
ms_search_form_ids:
  - docs/learn-smb-docs/business-central/finance-how-use-edocuments.md
  - docs/learn-smb-docs/business-central/LocalFunctionality/France/finance-sales-invoice-specifics.md
  - docs/learn-smb-docs/business-central/sales-how-invoice-sales.md
  - docs/learn-smb-docs/business-central/sales-how-register-new-customers.md
  - docs/learn-smb-docs/business-central/value-chain-howto-sales.md
counts:
  fields: 0
  procedures: 28
  events: 11
  subscribers: 0
  controls: 104
  actions: 36
relations:
  out: 1
  referenced_by: 0
  pages: 1
  extended_by: 7
  event_subscribers: 7
  calls: 19
  called_by: 10
  implements: 0
---

# Page 43 "Sales Invoice"

> Page 43 "Sales Invoice" in Base Application (Microsoft.Sales.Document). 5 public procedures, 11 events. Present since at least BC23, still in BC30, changed in BC25-27, BC29.

Base Application · Microsoft.Sales.Document · BC23-30 · [source at ea08af5e](https://github.com/microsoft/BCApps/blob/ea08af5ef2d6a9b5c5af4a029288abbe2c883220/src/Layers/W1/BaseApp/Sales/Document/SalesInvoice.Page.al) · facts from BC29

## Properties

| Property | Value |
|---|---|
| Caption | Sales Invoice |
| SourceTable | Sales Header |
| PageType | Document |

## Fields on this page

Layout controls in source order, grouped by the container they sit in. Shows: the table field a control is bound to (or its expression as written); ToolTip: the control's own, else the bound field's (marked).

| Group | Control | Shows | ToolTip |
|---|---|---|---|
| General | No. | [No.](../table/36.md#fields) | Specifies the number of the involved entry or record, according to the specified number series. |
|  | Customer No. | [Sell-to Customer No.](../table/36.md#fields) | Specifies the number of the customer who will receive the products and be billed by default. |
|  | Customer Name | [Sell-to Customer Name](../table/36.md#fields) | Specifies the name of the customer who will receive the products and be billed by default. |
|  | Customer Name 2 | [Sell-to Customer Name 2](../table/36.md#fields) | Specifies an additional part of the name of the customer who will receive the products and be billed by default. <small>from the table field</small> |
|  | Registration Number | [Registration Number](../table/36.md#fields) | Specifies the customer's registration number. <small>from the table field</small> |
|  | Posting Description | [Posting Description](../table/36.md#fields) | Specifies additional posting information for the document. After you post the document, the description can add detail to vendor and customer ledger entries. <small>from the table field</small> |
| Sell-to | Address | [Sell-to Address](../table/36.md#fields) | Specifies the address where the customer is located. <small>from the table field</small> |
|  | Address 2 | [Sell-to Address 2](../table/36.md#fields) | Specifies additional address information. <small>from the table field</small> |
|  | City | [Sell-to City](../table/36.md#fields) | Specifies the city of the customer on the sales document. <small>from the table field</small> |
| Control60 | Sell-to County | [Sell-to County](../table/36.md#fields) | Specifies the state, province or county of the address. <small>from the table field</small> |
| Sell-to | Post Code | [Sell-to Post Code](../table/36.md#fields) | Specifies the postal code. |
|  | Country/Region Code | [Sell-to Country/Region Code](../table/36.md#fields) | Specifies the country or region of the address. |
|  | Contact No. | [Sell-to Contact No.](../table/36.md#fields) | Specifies the number of the contact person that the sales document will be sent to. <small>from the table field</small> |
|  | Phone No. | `SellToContact."Phone No."` | Specifies the telephone number of the contact person that the sales document will be sent to. |
|  | Mobile Phone No. | `SellToContact."Mobile Phone No."` | Specifies the mobile telephone number of the contact person that the sales document will be sent to. |
|  | Email | `SellToContact."E-Mail"` | Specifies the email address of the contact person that the sales document will be sent to. |
| General | Contact | [Sell-to Contact](../table/36.md#fields) | Specifies the name of the person to contact at the customer. |
|  | Your Reference | [Your Reference](../table/36.md#fields) | Specifies the customer's reference. The contents will be printed on sales documents. |
|  | Document Date | [Document Date](../table/36.md#fields) | Specifies the date when the related document was created. <small>from the table field</small> |
|  | Posting Date | [Posting Date](../table/36.md#fields) | Specifies the date when the posting of the sales document will be recorded. <small>from the table field</small> |
|  | VAT Reporting Date | [VAT Reporting Date](../table/36.md#fields) | Specifies the date used to include entries on VAT reports in a VAT period. This is either the date that the document was created or posted, depending on your setting on the General Ledger Setup page. <small>from the table field</small> |
|  | Due Date | [Due Date](../table/36.md#fields) | Specifies when the sales invoice must be paid. <small>from the table field</small> |
|  | Incoming Document Entry No. | [Incoming Document Entry No.](../table/36.md#fields) | Specifies the number of the incoming document that this sales document is created for. <small>from the table field</small> |
|  | External Document No. | [External Document No.](../table/36.md#fields) | Specifies a document number that refers to the customer's or vendor's numbering system. <small>from the table field</small> |
|  | Salesperson Code | [Salesperson Code](../table/36.md#fields) | Specifies the name of the salesperson who is assigned to the customer. <small>from the table field</small> |
|  | Campaign No. | [Campaign No.](../table/36.md#fields) | Specifies the number of the campaign that the document is linked to. |
|  | Responsibility Center | [Responsibility Center](../table/36.md#fields) | Specifies the code of the responsibility center, such as a distribution hub, that is associated with the involved user, company, customer, or vendor. <small>from the table field</small> |
|  | Assigned User ID | [Assigned User ID](../table/36.md#fields) | Specifies the ID of the user who is responsible for the document. <small>from the table field</small> |
|  | Status | [Status](../table/36.md#fields) | Specifies whether the document is open, waiting to be approved, has been invoiced for prepayment, or has been released to the next stage of processing. <small>from the table field</small> |
|  | Job Queue Status | [Job Queue Status](../table/36.md#fields) | Specifies the status of a job queue entry or task that handles the posting of sales invoices. |
| Work Description | WorkDescription | `WorkDescription` | Specifies the products or service being offered |
| Content | SalesLines | part [Page 47 "Sales Invoice Subform"](../page/47.md) | — |
| Invoice Details | Currency Code | [Currency Code](../table/36.md#fields) | Specifies the currency of amounts on the sales document. <small>from the table field</small> |
|  | Company Bank Account Code | [Company Bank Account Code](../table/36.md#fields) | Specifies the bank account to use for bank information when the document is printed. <small>from the table field</small> |
|  | Shipment Date | [Shipment Date](../table/36.md#fields) | Specifies when items on the document are shipped or were shipped. A shipment date is usually calculated from a requested delivery date plus lead time. <small>from the table field</small> |
| Control58 | Quote No. | [Quote No.](../table/36.md#fields) | Specifies the number of the sales quote that the sales order was created from. You can track the number to sales quote documents that you have printed, saved, or emailed. <small>from the table field</small> |
| Invoice Details | Prices Including VAT | [Prices Including VAT](../table/36.md#fields) | Specifies if the Unit Price and Line Amount fields on document lines should be shown with or without VAT. <small>from the table field</small> |
|  | VAT Country/Region Code | [VAT Country/Region Code](../table/36.md#fields) | Specifies the country or region code for the VAT. <small>from the table field</small> |
|  | VAT Registration No. | [VAT Registration No.](../table/36.md#fields) | Specifies the customer's VAT registration number for customers. <small>from the table field</small> |
|  | Gen. Bus. Posting Group | [Gen. Bus. Posting Group](../table/36.md#fields) | Specifies the general business posting group that the sales document is linked to. The general business posting group is used to link the sales document to the appropriate general ledger account. <small>from the table field</small> |
|  | VAT Bus. Posting Group | [VAT Bus. Posting Group](../table/36.md#fields) | Specifies the VAT specification of the involved customer or vendor to link transactions made for this record with the appropriate general ledger account according to the VAT posting setup. <small>from the table field</small> |
|  | Customer Posting Group | [Customer Posting Group](../table/36.md#fields) | Specifies the customer's market type to link business transactions to. <small>from the table field</small> |
|  | Payment Terms Code | [Payment Terms Code](../table/36.md#fields) | Specifies a formula that calculates the payment due date, payment discount date, and payment discount amount. <small>from the table field</small> |
|  | Payment Method Code | [Payment Method Code](../table/36.md#fields) | Specifies how to make payment, such as with bank transfer, cash, or check. <small>from the table field</small> |
|  | Reason Code | [Reason Code](../table/36.md#fields) | Specifies the reason code, a supplementary source code that enables you to trace the document. <small>from the table field</small> |
|  | EU 3-Party Trade | [EU 3-Party Trade](../table/36.md#fields) | Specifies if the transaction is related to trade with a third party within the EU. <small>from the table field</small> |
| Control174 | Payment Service | `Rec.GetSelectedPaymentServicesText()` | Specifies the online payment service, such as PayPal, that customers can use to pay the sales document. |
| Invoice Details | Shortcut Dimension 1 Code | [Shortcut Dimension 1 Code](../table/36.md#fields) | Specifies the code for Shortcut Dimension 1, which is one of two global dimension codes that you set up in the General Ledger Setup window. <small>from the table field</small> |
|  | Shortcut Dimension 2 Code | [Shortcut Dimension 2 Code](../table/36.md#fields) | Specifies the code for Shortcut Dimension 2, which is one of two global dimension codes that you set up in the General Ledger Setup window. <small>from the table field</small> |
|  | Payment Discount % | [Payment Discount %](../table/36.md#fields) | Specifies the payment discount percentage granted if the customer pays on or before the date entered in the Pmt. Discount Date field. |
|  | Pmt. Discount Date | [Pmt. Discount Date](../table/36.md#fields) | Specifies the date on which the amount in the entry must be paid for a payment discount to be granted. <small>from the table field</small> |
|  | Journal Templ. Name | [Journal Templ. Name](../table/36.md#fields) | Specifies the name of the journal template in which the sales header is to be posted. <small>from the table field</small> |
|  | Direct Debit Mandate ID | [Direct Debit Mandate ID](../table/36.md#fields) | Specifies the direct-debit mandate that the customer has signed to allow direct debit collection of payments. <small>from the table field</small> |
|  | Location Code | [Location Code](../table/36.md#fields) | Specifies the code for the location from where the items are shipped. When you select the customer and the customer has a location assigned, the value is taken from the Customer card. If the customer has no location, but a Responsibility Center is populated, the location code is taken from the Respo... <small>from the table field</small> |
| Control200 | Ship-to | `ShipToOptions` | Specifies the address that the products on the sales document are shipped to. Default (Sell-to Address): The same as the customer's sell-to address. Alternate Ship-to Address: One of the customer's alternate ship-to addresses. Custom Address: Any ship-to address that you specify in the fields below. |
| Control202 | Code | [Ship-to Code](../table/36.md#fields) | Specifies the code for another shipment address than the customer's own address, which is entered by default. |
|  | Name | [Ship-to Name](../table/36.md#fields) | Specifies the name that products on the sales document will be shipped to. |
|  | Name 2 | [Ship-to Name 2](../table/36.md#fields) | Specifies an additional part of the name that products on the sales document will be shipped to. <small>from the table field</small> |
|  | Address | [Ship-to Address](../table/36.md#fields) | Specifies the address that products on the sales document will be shipped to. <small>from the table field</small> |
|  | Address 2 | [Ship-to Address 2](../table/36.md#fields) | Specifies additional address information. <small>from the table field</small> |
|  | City | [Ship-to City](../table/36.md#fields) | Specifies the city of the customer on the sales document. <small>from the table field</small> |
| Control82 | Ship-to County | [Ship-to County](../table/36.md#fields) | Specifies the state, province or county of the address. <small>from the table field</small> |
| Control202 | Post Code | [Ship-to Post Code](../table/36.md#fields) | Specifies the postal code. |
|  | Country/Region | [Ship-to Country/Region Code](../table/36.md#fields) | Specifies the customer's country/region. |
| Control200 | Phone No. | [Ship-to Phone No.](../table/36.md#fields) | Specifies the telephone number of the company's shipping address. <small>from the table field</small> |
|  | Contact | [Ship-to Contact](../table/36.md#fields) | Specifies the name of the contact person at the address that products on the sales document will be shipped to. |
| Shipment Method | Code | [Shipment Method Code](../table/36.md#fields) | Specifies how items on the sales document are shipped to the customer. |
|  | Agent | [Shipping Agent Code](../table/36.md#fields) | Specifies which shipping agent is used to transport the items on the sales document to the customer. |
|  | Agent service | [Shipping Agent Service Code](../table/36.md#fields) | Specifies which shipping agent service is used to transport the items on the sales document to the customer. |
|  | Package Tracking No. | [Package Tracking No.](../table/36.md#fields) | Specifies the shipping agent's package number. <small>from the table field</small> |
| Control203 | Bill-to | `BillToOptions` | Specifies the customer that the sales invoice will be sent to. Default (Customer): The same as the customer on the sales invoice. Another Customer: Any customer that you specify in the fields below. |
| Control205 | Name | [Bill-to Name](../table/36.md#fields) | Specifies the customer to whom you will send the sales invoice, when different from the customer that you are selling to. |
|  | Name 2 | [Bill-to Name 2](../table/36.md#fields) | Specifies an additional part of the name of the customer that you send or sent the invoice or credit memo to. <small>from the table field</small> |
|  | Address | [Bill-to Address](../table/36.md#fields) | Specifies the address of the customer that you will send the invoice to. <small>from the table field</small> |
|  | Address 2 | [Bill-to Address 2](../table/36.md#fields) | Specifies additional address information. <small>from the table field</small> |
|  | City | [Bill-to City](../table/36.md#fields) | Specifies the city of the customer on the sales document. <small>from the table field</small> |
| Control85 | Bill-to County | [Bill-to County](../table/36.md#fields) | Specifies the state, province or county of the address. <small>from the table field</small> |
| Control205 | Post Code | [Bill-to Post Code](../table/36.md#fields) | Specifies the postal code. |
|  | Country/Region | [Bill-to Country/Region Code](../table/36.md#fields) | Specifies the country or region of the address. |
|  | Contact No. | [Bill-to Contact No.](../table/36.md#fields) | Specifies the number of the contact the invoice will be sent to. <small>from the table field</small> |
|  | Contact | [Bill-to Contact](../table/36.md#fields) | Specifies the name of the person you should contact at the customer you are sending the invoice to. |
|  | Phone No. | `BillToContact."Phone No."` | Specifies the telephone number of the person you should contact at the customer you are sending the invoice to. |
|  | Mobile Phone No. | `BillToContact."Mobile Phone No."` | Specifies the mobile telephone number of the person you should contact at the customer you are sending the invoice to. |
|  | Email | `BillToContact."E-Mail"` | Specifies the email address of the person you should contact at the customer you are sending the invoice to. |
| Foreign Trade | Transaction Specification | [Transaction Specification](../table/36.md#fields) | Specifies a specification of the document's transaction, for the purpose of reporting to INTRASTAT. <small>from the table field</small> |
|  | Transaction Type | [Transaction Type](../table/36.md#fields) | Specifies the type of transaction that the document represents, for the purpose of reporting to INTRASTAT. <small>from the table field</small> |
|  | Transport Method | [Transport Method](../table/36.md#fields) | Specifies the transport method, for the purpose of reporting to INTRASTAT. <small>from the table field</small> |
|  | Exit Point | [Exit Point](../table/36.md#fields) | Specifies the point of exit through which you ship the items out of your country/region, for reporting to Intrastat. <small>from the table field</small> |
|  | Area | [Area](../table/36.md#fields) | Specifies the country or region of origin for the purpose of Intrastat reporting. <small>from the table field</small> |
|  | Language Code | [Language Code](../table/36.md#fields) | Specifies the language to be used on printouts for this document. <small>from the table field</small> |
|  | Format Region | [Format Region](../table/36.md#fields) | Specifies the format to be used on printouts for this document. <small>from the table field</small> |
| FactBoxes | Document Check | part [Page 9119 "Sales Doc. Check Factbox"](../page/9119.md) | — |
|  | Documents | part [Page 1178 "Doc. Attachment List Factbox"](../page/1178.md) | — |
|  | Control31 | part [Page 9103 "Pending Approval FactBox"](../page/9103.md) | — |
|  | Control1903720907 | part [Page 9080 "Sales Hist. Sell-to FactBox"](../page/9080.md) | — |
|  | Control1907234507 | part [Page 9081 "Sales Hist. Bill-to FactBox"](../page/9081.md) | — |
|  | Control1902018507 | part [Page 9082 "Customer Statistics FactBox"](../page/9082.md) | — |
|  | Control1900316107 | part [Page 9084 "Customer Details FactBox"](../page/9084.md) | — |
|  | Control1906127307 | part [Page 9087 "Sales Line FactBox"](../page/9087.md) | — |
|  | Control1901314507 | part [Page 9089 "Item Invoicing FactBox"](../page/9089.md) | — |
|  | IncomingDocAttachFactBox | part [Page 193 "Incoming Doc. Attach. FactBox"](../page/193.md) | — |
|  | ApprovalFactBox | part [Page 9092 "Approval FactBox"](../page/9092.md) | — |
|  | Control1907012907 | part [Page 9108 "Resource Details FactBox"](../page/9108.md) | — |
|  | WorkflowStatus | part [Page 1528 "Workflow Status FactBox"](../page/1528.md) | — |

## Actions

| Group | Action | ToolTip | Runs |
|---|---|---|---|
| Invoice | Statistics | View statistical information, such as the value of posted entries, for the record. | [Page 160 "Sales Statistics"](../page/160.md) |
|  | Customer Statistics | View statistical information, such as the value of posted entries, for the sell-to customer on the sales document. | [Page 151 "Customer Statistics"](../page/151.md) |
|  | Comments | View or add comments for the record. | [Page 67 "Sales Comment Sheet"](../page/67.md) |
|  | Approvals | View a list of the records that are waiting to be approved. For example, you can see who requested the record to be approved, when it was sent, and when it is due to be approved. |  |
|  | Customer | View or edit detailed information about the customer on the sales document. | [Page 21 "Customer Card"](../page/21.md) |
|  | Dimensions | View or edit dimensions, such as area, project, or department, that you can assign to sales and purchase documents to distribute costs and analyze transaction history. |  |
|  | Attachments | Add a file as an attachment. You can attach images as well as documents. |  |
| History | Interaction Log Entries | View a list of interaction log entries related to this document. |  |
| Approval | Approve | Approve the requested changes. |  |
|  | Reject | Reject the approval request. |  |
|  | Delegate | Delegate the approval to a substitute approver. |  |
|  | Comments | View or add comments for the record. |  |
| Release | Release | Release the document to the next stage of processing. You must reopen the document before you can make changes to it. |  |
|  | Reopen | Reopen the document to change it after it has been approved. Approved documents have the Released status and must be opened before they can be changed. |  |
|  | Reject IC Sales Invoice | Deletes the invoice and sends the rejection to the company that created it. |  |
| Functions | Create Purchase Invoice | Create a new purchase invoice to buy all the items that are required by the sales document, even if some of the items are already available. |  |
|  | Get Recurring Sales Lines | Insert sales document lines that you have set up for the customer as recurring. Recurring sales lines could be for a monthly replenishment order or a fixed freight expense. |  |
|  | Calculate Invoice Discount | Calculate the invoice discount for the entire sales document when all sales invoice lines are entered. |  |
|  | Copy Document | Copy document lines and header information from another sales document to this document. You can copy a posted sales invoice into a new sales invoice to quickly create a similar document. |  |
|  | Move Negative Lines | Prepare to create a replacement sales order in a sales return process. |  |
| Incoming Document | View Incoming Document | View any incoming document records and file attachments that exist for the entry or document. |  |
|  | Select Incoming Document | Select an incoming document record and file attachment that you want to link to the entry or document. |  |
|  | Create Incoming Document from File | Create an incoming document record by selecting a file to attach, and then link the incoming document record to the entry or document. |  |
|  | Remove Incoming Document | Remove any incoming document records and file attachments. |  |
| Request Approval | Send Approval Request | Request approval of the document. |  |
|  | Cancel Approval Request | Cancel the approval request. |  |
| Power Automate | Create approval flow | Create a new flow in Power Automate from a list of relevant flow templates. |  |
| Posting | Post | Finalize the document or journal by posting the amounts and quantities to the related accounts in your company books. |  |
|  | Post and New | Post the sales document and create a new, empty one. |  |
|  | Post and Send | Finalize and prepare to send the document according to the customer's sending profile, such as attached to an email. The Send document to window opens first so you can confirm or select a sending profile. |  |
|  | Preview Posting | Review the different types of entries that will be created when you post the document or journal. |  |
|  | Draft Invoice | View or print the sales invoice as a draft before you perform the actual posting. |  |
|  | Pro Forma Invoice | View or print the pro forma sales invoice. |  |
|  | Test Report | View a test report so that you can find and correct any errors before you perform the actual posting of the journal or document. |  |
|  | Remove From Job Queue | Remove the scheduled processing of this record from the job queue. |  |
|  | Attach as PDF | Create a PDF file and attach it to the document. |  |

## Events published

- `OnAfterOnAfterGetRecord(var SalesHeader: Record "Sales Header")` (integration)
  - subscribers: [Codeunit 9070 "Document Errors Mgt."](../codeunit/9070.md) OnAfterOnAfterGetRecordSalesInvoice
- `OnBeforeShowPreview(var SalesHeader: Record "Sales Header")` (integration)
- `OnPostOnAfterSetDocumentIsPosted(SalesHeader: Record "Sales Header"; var IsScheduledPosting: Boolean; var DocumentIsPosted: Boolean)` (integration)
- `OnPostOnBeforeSalesHeaderInsert(var SalesHeader: Record "Sales Header")` (integration)
- `OnBeforeValidateShipToOptions(var SalesHeader: Record "Sales Header"; ShipToOptions: Option; var IsHandled: Boolean)` (integration)
- `OnAfterValidateShipToOptions(var SalesHeader: Record "Sales Header"; ShipToOptions: Option)` (integration)
- `OnPostDocumentBeforeNavigateAfterPosting(var SalesHeader: Record "Sales Header"; var PostingCodeunitID: Integer; var Navigate: Enum "Navigate After Posting"; DocumentIsPosted: Boolean; var IsHandled: Boolean)` (integration)
- `OnBeforeOnDeleteRecord(var SalesHeader: Record "Sales Header"; var Result: Boolean; var IsHandled: Boolean)` (integration)
- `OnBeforeOnQueryClosePage(var SalesHeader: Record "Sales Header"; DocumentIsPosted: Boolean; CloseAction: Action; var Result: Boolean; var IsHandled: Boolean)` (integration)
- `OnBeforeLookupBillToName(var Customer: Record Customer; SalesHeader: Record "Sales Header")` (integration)
- `OnPostDocumentOnElseCaseNavigateAfterPosting(var SalesHeader: Record "Sales Header"; PostingCodeunitID: Integer; Navigate: Enum "Navigate After Posting")` (integration)

## Trigger event subscribers

- OnAfterValidateEvent(Sell-to Customer Name): [Codeunit 170 "Standard Codes Mgt."](../codeunit/170.md) OnAfterValidateSalesInvoiceSellToCustomerName
- OnAfterValidateEvent(Sell-to Customer No.): [Codeunit 170 "Standard Codes Mgt."](../codeunit/170.md) OnAfterValidateSalesInvoiceSellToCustomerNo
- OnClosePageEvent: [Codeunit 1508 "Notification Lifecycle Handler"](../codeunit/1508.md) OnCloseSalesInvoice
- OnModifyRecordEvent: [Codeunit 9070 "Document Errors Mgt."](../codeunit/9070.md) OnModifyRecordEventSalesInvoice
- OnOpenPageEvent: [Codeunit 1508 "Notification Lifecycle Handler"](../codeunit/1508.md) OnOpenSalesInvoice, [Codeunit 1952 "LP Subscribers"](../codeunit/1952.md) OnOpenSalesInvoice

## Procedures

- `CallPostDocument(PostingCodeunitID: Integer; Navigate: Enum "Navigate After Posting")`: Calls the document posting procedure with the specified posting codeunit and navigation option.
- `RunBackgroundCheck()`: Runs a background check for document errors.
- `SetSkipConfirmationDialogOnClosing(Skip: Boolean)`: Sets whether to skip the confirmation dialog when closing the page.
- `UpdatePaymentService()` (protected)
- `SetPostingGroupEditable()`: Sets whether the posting group field should be editable based on customer settings.

Plus 12 local procedures.

## Triggers

OnAfterGetCurrRecord, OnAfterGetRecord, OnDeleteRecord, OnInit, OnInsertRecord, OnNewRecord, OnOpenPage, OnQueryClosePage

## Relations

- source table [Table 36 "Sales Header"](../table/36.md)

## Pages and codeunits on this table

- [Page 9301 "Sales Invoice List"](../page/9301.md) (card page)

## Extended by

- [Page extension 1957 "LPP Sales Invoice"](../pageextension/1957.md)
- [Page extension 20256 "Sales Invoice Ext"](../pageextension/20256.md)
- [Page extension 30113 "Shpfy Sales Invoice"](../pageextension/30113.md)
- [Page extension 5021 "SD Sales Invoice"](../pageextension/5021.md)
- [Page extension 5585 "Incoming Doc. Sales Inv."](../pageextension/5585.md)
- [Page extension 6128 "E-Doc. Sales Invoice"](../pageextension/6128.md)
- [Page extension 8066 "Sales Invoice"](../pageextension/8066.md)

## 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 1330 "Instruction Mgt."](../codeunit/1330.md) (5 calls: `PostDocument → IsEnabled`, `PostDocument → ShowPostedConfirmationMessageCode`, `ShowPostedConfirmationMessage → ShowConfirm`, …)
- [Codeunit 1535 "Approvals Mgmt."](../codeunit/1535.md) (3 calls: `SetControlAppearance → CanCancelApprovalForRecord`, `SetControlAppearance → HasOpenApprovalEntries`, `SetControlAppearance → HasOpenApprovalEntriesForCurrentUser`)
- [Codeunit 1630 "Office Management"](../codeunit/1630.md) (2 calls: `OnOpenPage → CheckForExistingInvoice`, `PostDocument → IsAvailable`)
- [Codeunit 427 "ICInboxOutboxMgt"](../codeunit/427.md) (2 calls: `OnAfterGetRecord → IsSalesHeaderFromIncomingIC`, `OnOpenPage → IsSalesHeaderFromIncomingIC`)
- [Codeunit 9070 "Document Errors Mgt."](../codeunit/9070.md) (2 calls: `CheckShowBackgrValidationNotification → CheckShowEnableBackgrValidationNotification`, `SetControlAppearance → BackgroundValidationEnabled`)
- [Codeunit 1302 "Customer Mgt."](../codeunit/1302.md) (1 call: `UpdateShipToBillToGroupVisibility → CalculateShipBillToOptions`)
- [Codeunit 1320 "Lines Instruction Mgt."](../codeunit/1320.md) (1 call: `PostDocument → SalesCheckAllLinesHaveQuantityAssigned`)
- [Codeunit 1400 "DocumentNoVisibility"](../codeunit/1400.md) (1 call: `SetDocNoVisible → SalesDocumentNoIsVisible`)
- [Codeunit 1543 "Workflow Webhook Management"](../codeunit/1543.md) (1 call: `SetControlAppearance → GetCanRequestAndCanCancel`)
- [Codeunit 1563 "Privacy Notice"](../codeunit/1563.md) (1 call: `OnInit → GetPrivacyNoticeApprovalState`)
- [Codeunit 365 "Format Address"](../codeunit/365.md) (1 call: `ActivateFields → UseCounty`)
- [Codeunit 404 "IC Feedback"](../codeunit/404.md) (1 call: `ShowPostedConfirmationMessage → ShowIntercompanyMessage`)
- [Codeunit 457 "Environment Information"](../codeunit/457.md) (1 call: `OnOpenPage → IsSaaS`)
- [Codeunit 57 "Document Totals"](../codeunit/57.md) (1 call: `SaveInvoiceDiscountAmount → SalesRedistributeInvoiceDiscountAmountsOnDocument`)
- [Codeunit 5700 "User Setup Management"](../codeunit/5700.md) (1 call: `OnNewRecord → GetSalesFilter`)
- [Codeunit 6400 "Flow Service Management"](../codeunit/6400.md) (1 call: `OnInit → GetPowerAutomatePrivacyNoticeId`)
- [Codeunit 700 "Page Management"](../codeunit/700.md) (1 call: `PostDocument → PageRun`)
- [Codeunit 799 "VAT Reporting Date Mgt"](../codeunit/799.md) (1 call: `OnOpenPage → IsVATDateEnabled`)
- [Codeunit 81 "Sales-Post (Yes/No)"](../codeunit/81.md) (1 call: `ShowPreview → Preview`)

## Called by

- [Codeunit 1002 "Job Create-Invoice"](../codeunit/1002.md) (1 call: `OpenSalesInvoice → (object)`)
- [Codeunit 1304 "Sales-Quote to Invoice Yes/No"](../codeunit/1304.md) (1 call: `ShowInvoice → (object)`)
- [Codeunit 1322 "Correct PstdSalesInv (Yes/No)"](../codeunit/1322.md) (1 call: `CancelPostedInvoiceAndOpenNewSalesInvoice → (object)`)
- [Codeunit 1339 "Cancel Posted Sales Cr. Memo"](../codeunit/1339.md) (1 call: `CancelPostedCrMemo → (object)`)
- [Codeunit 5530 "Calc. Item Availability"](../codeunit/5530.md) (1 call: `RunSalesHeaderPage → (object)`)
- [Codeunit 6620 "Copy Document Mgt."](../codeunit/6620.md) (1 call: `ShowSalesDoc → (object)`)
- [Codeunit 980 "Payment Registration Mgt."](../codeunit/980.md) (1 call: `ShowSalesHeaderRecords → (object)`)
- [Codeunit 99000832 "Sales Line-Reserve"](../codeunit/99000832.md) (1 call: `OnLookupDocument → (object)`)
- [Table 18 "Customer"](../table/18.md) (1 call: `CreateAndShowNewInvoice → (object)`)
- [Table 7275 "Sales Line AI Suggestions"](../table/7275.md) (1 call: `RunSalesHeaderPage → (object)`)

## Across versions

- Present in: BC23-30
- Changed (declaration) in: BC25-27, BC29

## Countries that replace it

[IT](../../localizations/it.md), [NO](../../localizations/no.md)

## Documented on Microsoft Learn

- [Use e-documents in sales](https://learn.microsoft.com/dynamics365/business-central/finance-how-use-edocuments)
- [Deliver sales invoices with French specifics](https://learn.microsoft.com/dynamics365/business-central/LocalFunctionality/France/finance-sales-invoice-specifics)
- [Invoice sales](https://learn.microsoft.com/dynamics365/business-central/sales-how-invoice-sales)
- [Register new customers by creating a Customer Card](https://learn.microsoft.com/dynamics365/business-central/sales-how-register-new-customers)
- [Sustainability value chain in sales](https://learn.microsoft.com/dynamics365/business-central/value-chain-howto-sales)

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: "page", object_name: "Sales Invoice")`, then `bcatlas_get_procedure_body` or `bcatlas_get_neighbors` on the returned id.
