Table "Sales Cr.Memo Line"
Stores line-level details for posted sales credit memos including credited items, quantities, and amounts.
Properties
| Name | Value |
|---|---|
| Caption | Sales Cr.Memo Line |
| DrillDownPageID | Page Microsoft.Sales.History."Posted Sales Credit Memo Lines" |
| LookupPageID | Page Microsoft.Sales.History."Posted Sales Credit Memo Lines" |
| Permissions | TableData "Item Ledger Entry" = r, TableData "Value Entry" = r |
| DataClassification | CustomerContent |
Fields
| Name | Type | Description |
|---|---|---|
| "Sell-to Customer No." | Code[20] | Specifies the customer number who received the credited items. |
| "Document No." | Code[20] | Specifies the document number of the posted credit memo header. |
| "Line No." | Integer | Specifies the sequential line number within the credit memo. |
| Type | Enum Microsoft.Sales.Document."Sales Line Type" | Specifies the type of entity on the line such as Item, G/L Account, or Resource. |
| "No." | Code[20] | Specifies the number of the item, G/L account, resource, or other entity on the line. |
| "Location Code" | Code[10] | Specifies the location from which items were shipped or returned. |
| "Posting Group" | Code[20] | Specifies the posting group used to post the line to the general ledger. |
| "Shipment Date" | Date | Specifies the date when items were shipped related to this line. |
| Description | Text[100] | Specifies the description of the item, account, or resource on the line. |
| "Description 2" | Text[50] | Specifies additional description text for the line. |
| "Unit of Measure" | Text[50] | Specifies the unit of measure description for the line item. |
| Quantity | Decimal | Specifies the credited quantity on the line. |
| "Unit Price" | Decimal | Specifies the unit price of the item or resource on the line. |
| "Unit Cost (LCY)" | Decimal | Specifies the unit cost in local currency for the line item. |
| "VAT %" | Decimal | Specifies the VAT percentage applied to the line. |
| "Line Discount %" | Decimal | Specifies the line discount percentage applied to the line. |
| "Line Discount Amount" | Decimal | Specifies the line discount amount applied to the line. |
| Amount | Decimal | Specifies the line amount excluding VAT. |
| "Amount Including VAT" | Decimal | Specifies the line amount including VAT. |
| "Allow Invoice Disc." | Boolean | Indicates whether the line is included in invoice discount calculations. |
| "Gross Weight" | Decimal | Specifies the gross weight of the items on the line. |
| "Net Weight" | Decimal | Specifies the net weight of the items on the line. |
| "Units per Parcel" | Decimal | Specifies the number of units per parcel for shipping. |
| "Unit Volume" | Decimal | Specifies the volume of a single unit of the item. |
| "Appl.-to Item Entry" | Integer | Specifies the item ledger entry to apply this credit to. |
| "Shortcut Dimension 1 Code" | Code[20] | Specifies the first global dimension code used for analysis. |
| "Shortcut Dimension 2 Code" | Code[20] | Specifies the second global dimension code used for analysis. |
| "Customer Price Group" | Code[10] | Specifies the customer price group used for pricing on this line. |
| "Job No." | Code[20] | Specifies the project number associated with this line. |
| "Work Type Code" | Code[10] | Specifies the work type code for resource billing. |
| "Order No." | Code[20] | Specifies the original return order number for this line. |
| "Order Line No." | Integer | Specifies the original return order line number. |
| "Bill-to Customer No." | Code[20] | Specifies the customer number who receives the credit memo for billing. |
| "Inv. Discount Amount" | Decimal | Specifies the invoice discount amount applied to this line. |
| "Gen. Bus. Posting Group" | Code[20] | Specifies the general business posting group for the line. |
| "Gen. Prod. Posting Group" | Code[20] | Specifies the general product posting group for the line. |
| "VAT Calculation Type" | Enum Microsoft.Foundation.Enums."Tax Calculation Type" | Specifies the method used to calculate VAT on the line. |
| "Transaction Type" | Code[10] | Specifies the transaction type code for Intrastat reporting. |
| "Transport Method" | Code[10] | Specifies the transport method code for Intrastat reporting. |
| "Attached to Line No." | Integer | Specifies the parent line number for attached lines such as extended text. |
| "Exit Point" | Code[10] | Specifies the exit point for goods leaving the country for Intrastat. |
| "Area" | Code[10] | Specifies the area code for Intrastat reporting. |
| "Transaction Specification" | Code[10] | Specifies the transaction specification code for Intrastat reporting. |
| "Tax Category" | Code[10] | Specifies the tax category for electronic document reporting. |
| "Tax Area Code" | Code[20] | Specifies the tax area code for sales tax calculations. |
| "Tax Liable" | Boolean | Indicates whether the line is subject to sales tax. |
| "Tax Group Code" | Code[20] | Specifies the tax group code for sales tax calculations. |
| "VAT Clause Code" | Code[20] | Specifies the VAT clause code for legal reporting requirements. |
| "VAT Bus. Posting Group" | Code[20] | Specifies the VAT business posting group for tax calculations. |
| "VAT Prod. Posting Group" | Code[20] | Specifies the VAT product posting group for tax calculations. |
| "Blanket Order No." | Code[20] | Specifies the blanket order number this line is linked to. |
| "Blanket Order Line No." | Integer | Specifies the blanket order line number this line is linked to. |
| "VAT Base Amount" | Decimal | Specifies the base amount used for VAT calculations. |
| "Unit Cost" | Decimal | Specifies the unit cost in document currency. |
| "System-Created Entry" | Boolean | Indicates whether the line was created automatically by the system. |
| "Line Amount" | Decimal | Specifies the total line amount before invoice discount. |
| "VAT Difference" | Decimal | Specifies the difference between calculated and manually entered VAT. |
| "VAT Identifier" | Code[20] | Specifies the VAT identifier used to group VAT setup combinations. |
| "IC Partner Ref. Type" | Enum Microsoft.Intercompany.Partner."IC Partner Reference Type" | Specifies the type of intercompany partner reference. |
| "IC Partner Reference" | Code[20] | Specifies the intercompany partner reference for cross-company transactions. |
| "Prepayment Line" | Boolean | Indicates whether this is a prepayment credit memo line. |
| "IC Partner Code" | Code[20] | Specifies the intercompany partner code for cross-company transactions. |
| "Posting Date" | Date | Specifies the posting date of the credit memo line. |
| "IC Item Reference No." | Code[50] | Specifies the intercompany item reference number for cross-company transactions. |
| "Pmt. Discount Amount" | Decimal | Specifies the payment discount amount for the line. |
| "Line Discount Calculation" | Option | Specifies how the line discount was calculated. |
| "Dimension Set ID" | Integer | Specifies the unique identifier for the dimension set applied to this line. |
| "Job Task No." | Code[20] | Specifies the project task number associated with this line. |
| "Job Contract Entry No." | Integer | Specifies the project contract entry number for project billing. |
| "Deferral Code" | Code[10] | Specifies the deferral template code for revenue deferral. |
| "Variant Code" | Code[10] | Specifies the item variant code for the item on the line. |
| "Bin Code" | Code[20] | Specifies the bin code where the item is stored or was returned to. |
| "Qty. per Unit of Measure" | Decimal | Specifies the quantity per unit of measure for conversion. |
| "Unit of Measure Code" | Code[10] | Specifies the unit of measure code for the line item. |
| "Quantity (Base)" | Decimal | Specifies the quantity in the base unit of measure. |
| "FA Posting Date" | Date | Specifies the fixed asset posting date for depreciation. |
| "Depreciation Book Code" | Code[10] | Specifies the depreciation book code for fixed asset posting. |
| "Depr. until FA Posting Date" | Boolean | Indicates whether depreciation is calculated until the FA posting date. |
| "Duplicate in Depreciation Book" | Code[10] | Specifies another depreciation book to duplicate the posting to. |
| "Use Duplication List" | Boolean | Indicates whether to use the duplication list for fixed asset posting. |
| "Responsibility Center" | Code[10] | Specifies the responsibility center that processed this line. |
| "Item Category Code" | Code[20] | Specifies the item category code for the item on the line. |
| Nonstock | Boolean | Indicates whether the item is a catalog item not in regular inventory. |
| "Purchasing Code" | Code[10] | Specifies the purchasing code for special order handling. |
| "Item Reference No." | Code[50] | Specifies the item reference number for cross-reference lookup. |
| "Item Reference Unit of Measure" | Code[10] | Specifies the unit of measure from the item reference. |
| "Item Reference Type" | Enum Microsoft.Inventory.Item.Catalog."Item Reference Type" | Specifies the type of item reference used. |
| "Item Reference Type No." | Code[30] | Specifies the number associated with the item reference type. |
| "Appl.-from Item Entry" | Integer | Specifies the item ledger entry this credit was applied from. |
| "Return Receipt No." | Code[20] | Specifies the return receipt document number this line was created from. |
| "Return Receipt Line No." | Integer | Specifies the return receipt line number this line was created from. |
| "Return Reason Code" | Code[10] | Specifies the reason code for the return. |
| "Price Calculation Method" | Enum Microsoft.Pricing.Calculation."Price Calculation Method" | Specifies the method used to calculate prices on the line. |
| "Allow Line Disc." | Boolean | Indicates whether line discounts are allowed on this line. |
| "Customer Disc. Group" | Code[20] | Specifies the customer discount group for line discount calculations. |
| "Sell-to Customer Name" | Text[100] | Specifies the name of the sell-to customer from the customer record. |
| SystemId | Guid | |
| SystemCreatedAt | DateTime | |
| SystemCreatedBy | Guid | |
| SystemModifiedAt | DateTime | |
| SystemModifiedBy | Guid | |
| SystemCreatedByUserName | Text[50] | |
| SystemCreatedByFullName | Text[80] | |
| SystemModifiedByUserName | Text[50] | |
| SystemModifiedByFullName | Text[80] | |
| SystemRowVersion | BigInteger |
Methods
GetCurrencyCode
Retrieves the currency code from the sales credit memo header.
procedure GetCurrencyCode(): Code[10]
Returns
| Type | Description |
|---|---|
| Code[10] |
The currency code for this credit memo line. |
ShowDimensions
Opens a page displaying the dimensions associated with this credit memo line.
procedure ShowDimensions()
ShowItemTrackingLines
Opens a page displaying the item tracking lines for this credit memo line.
procedure ShowItemTrackingLines()
CalcVATAmountLines
Calculates VAT amount lines for all lines in the credit memo.
procedure CalcVATAmountLines(SalesCrMemoHeader: Record "Sales Cr.Memo Header"; var TempVATAmountLine: Record "VAT Amount Line" temporary)
Parameters
| Name | Type | Description |
|---|---|---|
| SalesCrMemoHeader | Table Microsoft.Sales.History."Sales Cr.Memo Header" |
The sales credit memo header to calculate VAT for. |
| TempVATAmountLine | Table Microsoft.Finance.VAT.Calculation."VAT Amount Line" |
Returns the calculated VAT amount lines. |
GetLineAmountExclVAT
Calculates the line amount excluding VAT.
procedure GetLineAmountExclVAT(): Decimal
Returns
| Type | Description |
|---|---|
| Decimal |
The line amount excluding VAT. |
GetLineAmountInclVAT
Calculates the line amount including VAT.
procedure GetLineAmountInclVAT(): Decimal
Returns
| Type | Description |
|---|---|
| Decimal |
The line amount including VAT. |
GetCreditMemoHeader
Retrieves the sales credit memo header for this line.
procedure GetCreditMemoHeader(): Record "Sales Cr.Memo Header"
Returns
| Type | Description |
|---|---|
| Table Microsoft.Sales.History."Sales Cr.Memo Header" |
The sales credit memo header record. |
GetCaptionClass
Retrieves the caption class for a specified field to handle VAT-inclusive pricing display.
procedure GetCaptionClass(FieldNumber: Integer): Text[80]
Parameters
| Name | Type | Description |
|---|---|---|
| FieldNumber | Integer |
The field number to get the caption class for. |
Returns
| Type | Description |
|---|---|
| Text[80] |
The caption class string for the field. |
RowID1
Generates a unique row identifier for item tracking purposes.
procedure RowID1(): Text[250]
Returns
| Type | Description |
|---|---|
| Text[250] |
The row identifier string. |
GetReturnRcptLines
Retrieves the return receipt lines associated with this credit memo line.
procedure GetReturnRcptLines(var TempReturnReceiptLine: Record "Return Receipt Line" temporary)
Parameters
| Name | Type | Description |
|---|---|---|
| TempReturnReceiptLine | Table Microsoft.Sales.History."Return Receipt Line" |
Returns the temporary return receipt lines. |
GetItemLedgEntries
Retrieves item ledger entries associated with this credit memo line.
procedure GetItemLedgEntries(var TempItemLedgEntry: Record "Item Ledger Entry" temporary; SetQuantity: Boolean)
Parameters
| Name | Type | Description |
|---|---|---|
| TempItemLedgEntry | Table Microsoft.Inventory.Ledger."Item Ledger Entry" |
Returns the temporary item ledger entries. |
| SetQuantity | Boolean |
Indicates whether to set quantities from value entries. |
FilterPstdDocLineValueEntries
Applies filters to value entries to retrieve entries for this posted document line.
procedure FilterPstdDocLineValueEntries(var ValueEntry: Record "Value Entry")
Parameters
| Name | Type | Description |
|---|---|---|
| ValueEntry | Table Microsoft.Inventory.Ledger."Value Entry" |
The value entry record to apply filters to. |
ShowItemReturnRcptLines
Opens a page displaying the return receipt lines for this credit memo line.
procedure ShowItemReturnRcptLines()
ShowLineComments
Opens a page displaying the comments for this credit memo line.
procedure ShowLineComments()
ShowShortcutDimCode
Retrieves the shortcut dimension codes for this credit memo line.
procedure ShowShortcutDimCode(var ShortcutDimCode: array[8] of Code[20])
Parameters
| Name | Type | Description |
|---|---|---|
| ShortcutDimCode | array[8] of Code[20] |
Returns the array of shortcut dimension codes. |
InitFromSalesLine
Initializes the credit memo line from a sales line during posting.
procedure InitFromSalesLine(SalesCrMemoHeader: Record "Sales Cr.Memo Header"; SalesLine: Record "Sales Line")
Parameters
| Name | Type | Description |
|---|---|---|
| SalesCrMemoHeader | Table Microsoft.Sales.History."Sales Cr.Memo Header" |
The sales credit memo header. |
| SalesLine | Table Microsoft.Sales.Document."Sales Line" |
The source sales line to initialize from. |
ShowDeferrals
Opens a page displaying the deferral schedule for this credit memo line.
procedure ShowDeferrals()
GetDocumentType
Retrieves the document type integer for this posted credit memo line.
procedure GetDocumentType(): Integer
Returns
| Type | Description |
|---|---|
| Integer |
The document type value as an integer. |
HasTypeToFillMandatoryFields
Determines whether the line has a type that requires mandatory fields to be filled.
procedure HasTypeToFillMandatoryFields(): Boolean
Returns
| Type | Description |
|---|---|
| Boolean |
True if the line type requires mandatory fields, otherwise false. |
FormatType
Formats the line type for display, handling blank types specially.
procedure FormatType(): Text
Returns
| Type | Description |
|---|---|
| Text |
The formatted type text. |
SetSecurityFilterOnRespCenter
Applies security filters based on the user's responsibility center setup.
procedure SetSecurityFilterOnRespCenter()
Events
OnAfterInitFromSalesLine
Raised after initializing a sales credit memo line from a sales line.
[IntegrationEvent(False,False)]
local procedure OnAfterInitFromSalesLine(var SalesCrMemoLine: Record "Sales Cr.Memo Line"; SalesCrMemoHeader: Record "Sales Cr.Memo Header"; SalesLine: Record "Sales Line")
Parameters
| Name | Type | Description |
|---|---|---|
| SalesCrMemoLine | Table Microsoft.Sales.History."Sales Cr.Memo Line" |
The sales credit memo line being initialized. |
| SalesCrMemoHeader | Table Microsoft.Sales.History."Sales Cr.Memo Header" |
The sales credit memo header. |
| SalesLine | Table Microsoft.Sales.Document."Sales Line" |
The source sales line. |
OnBeforeCalcVATAmountLines
Raised before calculating VAT amount lines for the sales credit memo.
[IntegrationEvent(False,False)]
local procedure OnBeforeCalcVATAmountLines(SalesCrMemoLine: Record "Sales Cr.Memo Line"; SalesCrMemoHeader: Record "Sales Cr.Memo Header"; var TempVATAmountLine: Record "VAT Amount Line" temporary; var IsHandled: Boolean)
Parameters
| Name | Type | Description |
|---|---|---|
| SalesCrMemoLine | Table Microsoft.Sales.History."Sales Cr.Memo Line" |
The sales credit memo line being processed. |
| SalesCrMemoHeader | Table Microsoft.Sales.History."Sales Cr.Memo Header" |
The sales credit memo header. |
| TempVATAmountLine | Table Microsoft.Finance.VAT.Calculation."VAT Amount Line" |
Temporary VAT amount lines to be calculated. |
| IsHandled | Boolean |
Set to true to skip default VAT calculation. |
OnBeforeShowDeferrals
Raised before showing the deferral schedule for the sales credit memo line.
[IntegrationEvent(False,False)]
local procedure OnBeforeShowDeferrals(var SalesCrMemoLine: Record "Sales Cr.Memo Line"; var IsHandled: Boolean)
Parameters
| Name | Type | Description |
|---|---|---|
| SalesCrMemoLine | Table Microsoft.Sales.History."Sales Cr.Memo Line" |
The sales credit memo line. |
| IsHandled | Boolean |
Set to true to skip default deferral display. |
OnGetItemLedgEntriesOnBeforeTempItemLedgEntryInsert
Raised before inserting a temporary item ledger entry when retrieving item ledger entries.
[IntegrationEvent(False,False)]
local procedure OnGetItemLedgEntriesOnBeforeTempItemLedgEntryInsert(var TempItemLedgerEntry: Record "Item Ledger Entry" temporary; ValueEntry: Record "Value Entry"; SetQuantity: Boolean)
Parameters
| Name | Type | Description |
|---|---|---|
| TempItemLedgerEntry | Table Microsoft.Inventory.Ledger."Item Ledger Entry" |
The temporary item ledger entry to be inserted. |
| ValueEntry | Table Microsoft.Inventory.Ledger."Value Entry" |
The source value entry. |
| SetQuantity | Boolean |
Indicates whether quantity should be set from the value entry. |
OnBeforeSetSecurityFilterOnRespCenter
Raised before setting security filter on responsibility center for sales credit memo lines.
[IntegrationEvent(False,False)]
local procedure OnBeforeSetSecurityFilterOnRespCenter(var SalesCrMemoLine: Record "Sales Cr.Memo Line"; var IsHandled: Boolean)
Parameters
| Name | Type | Description |
|---|---|---|
| SalesCrMemoLine | Table Microsoft.Sales.History."Sales Cr.Memo Line" |
The sales credit memo line to apply filters to. |
| IsHandled | Boolean |
Set to true to skip default security filter application. |
OnAfterGetVATPct
Raised after retrieving the VAT percentage for the sales credit memo line.
[IntegrationEvent(False,False)]
local procedure OnAfterGetVATPct(var SalesCrMemoLine: Record "Sales Cr.Memo Line"; var VATPct: Decimal)
Parameters
| Name | Type | Description |
|---|---|---|
| SalesCrMemoLine | Table Microsoft.Sales.History."Sales Cr.Memo Line" |
The sales credit memo line. |
| VATPct | Decimal |
The VAT percentage value. |