Add_ReferencedDocument

Methode (Function) · gibt Boolean zurück

Add_ReferencedDocument ist eine Methode der Klasse Aloaha_ZUGFeRD.XML im Aloaha ZUGFeRD SDK. Sie betrifft BT-132 (Referenz zur Bestellposition).

Beschreibung (aus der SDK-Dokumentation): BT-132-00, BG-X-47, BG-X-2: Referenced documents on item level (buyer order, quotation, contract, ultimate customer order). Replaces the existing reference of that type on the line item and sets the profile to Extended.

Rückgabe: True if the reference was stored, otherwise False (e.g. no line items, empty ReferencedLineID, invalid PositionNo, line item without line ID, or unsupported Doctype).

Deklaration

Public Function Add_ReferencedDocument(ByVal Doctype As iXML.WhichReferencedDocument, ByVal PositionNo As Long, ByVal IssuerAssignedID As String, ByVal ReferencedLineID As String, Optional ByVal IssueDateTime As String = "", Optional ByVal Document_DateFormat As String = "") As Boolean

Parameter

NameTypPflichtBeschreibung
DoctypeiXML.WhichReferencedDocumenterforderlichWhich type of document, BT-132-00, BG-X-47 or BG-X-2? GLOBAL_UltimateCustomerOrderReferencedDocument appends a document-level ultimate customer order
PositionNoLongerforderlichZero-based index of the line item to attach the reference to (also required to be valid for the document-level type)
IssuerAssignedIDStringerforderlichBT-X-21, BT-X-310, BT-X-24: Order ID, Document Number or Contract Number
ReferencedLineIDStringerforderlichBT-132, BT-X-311, BT-X-25: Line/Position Reference. Must not be empty
IssueDateTimeStringoptional (Standard: "")BT-X-22, BT-X-312, BT-X-26: Document Date YYYYMMDD; only stored if not empty
Document_DateFormatStringoptional (Standard: "")BT-X-22-0, BT-X-312-0, BT-X-26-0: Document Date Format. Usually 102 (no default is applied)

Aufruf (VB.NET)

Dim alo As New Aloaha_ZUGFeRD.XML(Aloaha_ZUGFeRD.iXML.ZUGFeRDProfile.comfort, False, LicenseKey)
' …
Dim ergebnis = alo.Add_ReferencedDocument(Doctype, PositionNo, IssuerAssignedID, ReferencedLineID)

Business Terms (EN 16931)

Artikel mit Add_ReferencedDocument

COM-Schnittstelle

Add_ReferencedDocument ist Mitglied der Schnittstelle Aloaha_ZUGFeRD.iXML (Position 167 von 328) und damit auch aus VB6, VBA/Access und anderen COM-Clients über CreateObject("Aloaha_ZUGFeRD.XML") aufrufbar. Neue Mitglieder werden immer am Ende von iXML angefügt, damit bestehende COM-Clients unverändert weiterlaufen; nach einem Update die Typbibliothek neu registrieren.

Quelle: XML-Dokumentationskommentare des Aloaha ZUGFeRD SDK (xml.vb). Gleiche Signatur in VB6/VBA über COM; in C# mit Semikolon.