THotPDF.AddFacturXAssociatedFile Method
ملخص الطريقة: THotPDF.AddFacturXAssociatedFile Method
التصريح
function AddFacturXAssociatedFile(const XMLBytes : TBytes; const ConformanceLevel : AnsiString; const FileName : AnsiString = 'factur-x.xml'; const Description : AnsiString = 'Factur-X invoice XML'; const Relationship : AnsiString = 'Alternative'; const Version : AnsiString = '1.0'; const CountryCode : AnsiString = ''): THPDFDictionaryObject;
الوحدة
HPDFDoc
المعاملات
| الاسم | الغرض |
|---|---|
XMLBytes | Invoice XML bytes embedded verbatim in the PDF/A-3 EmbeddedFile stream; the XML guideline or profile identifier must match ConformanceLevel |
ConformanceLevel | Allowed invoice profile or conformance level, such as EN 16931, EXTENDED, XRECHNUNG, or COMFORT for ZUGFeRD 1.0 |
FileName | Embedded XML filename written to /F, /UF, the EmbeddedFiles name tree, and the XMP DocumentFileName value |
الوصف | Optional Filespec /Desc text shown to consuming tools |
Relationship | Associated-file relationship written as /AFRelationship and allowed by the selected invoice profile |
Version | Invoice metadata version, including 1.0, 2p0, or a matching XRECHNUNG version such as 3.0 |
CountryCode | Regional policy code used by profile validation; use an empty value, DE, or FR |
قيمة الإرجاع
يعيد قاموس Filespec غير المباشر المسجل لملف XML الفاتورة الأساسي
ملاحظات الاستخدام
- اضبط PDFACompliance على 3A أو 3B أو 3U واستدع BeginDoc قبل استخدام هذا الأسلوب
- يرفض الأسلوب تراكيب اسم الملف والملف التعريفي وإصدار metadata غير الصالحة، بحيث يستخدم xrechnung.xml مع XRECHNUNG فقط، وZUGFeRD-invoice.xml مع ملفات ZUGFeRD 1.0 فقط، وzugferd-invoice.xml مع Version 2p0 فقط، وfactur-x.xml مع ملفات Factur-X الحالية
- يفحص الأسلوب guideline أو profile identifier في XML مقابل ConformanceLevel، بما في ذلك ZUGFeRD 1.0 profile URNs، وFactur-X profile URNs الحالية، ومجموعات French EXTENDED، واسم EN16931 XMP أو alias الملف التعريفي، وZUGFeRD 2.0 profile URNs، وXRechnung CII أو UBL profile URNs المعروفة مع إصدارات metadata المطابقة
- بالنسبة إلى XRECHNUNG مرر Version بالقيم 1.2 أو 2.0 أو 2.1 أو 2.2 أو 2.3 أو 3.0 للحفاظ على fx:Version؛ أما الاستدعاءات الحالية التي تترك Version الافتراضي عند 1.0 فتطبع إلى 3.0
- لحاويات ZUGFeRD 1.0 مرر FileName بالقيمة ZUGFeRD-invoice.xml، وVersion بالقيمة 1.0، وConformanceLevel بالقيم BASIC أو COMFORT أو EXTENDED
- لحاويات ZUGFeRD 2.0 مرر FileName بالقيمة zugferd-invoice.xml وVersion بالقيمة 2p0
- مرر CountryCode بالقيمة DE عندما يجب أن تتبع حاوية الفاتورة قواعد علاقة ZUGFeRD الألمانية؛ تتطلب MINIMUM وBASIC WL أن تكون Data هي AFRelationship، بينما تتطلب BASIC وEN 16931 وEXTENDED وXRECHNUNG القيمة Alternative
- مرر CountryCode بالقيمة FR عندما يجب أن تتبع الفاتورة قواعد Factur-X الفرنسية؛ يتم رفض XRECHNUNG ويمكن لـ BASIC وEN 16931 وEXTENDED وEXTENDED-CTC-FR وEXTENDED-B2B-FR استخدام Alternative أو Source أو Data
- يستخدم الأسلوب MIME type text/xml، ويكتب /Params /Size و/ModDate و/CheckSum، ويسجل Filespec في Catalog /AF، ويضيف مدخل Catalog /Names /EmbeddedFiles لأدوات استخراج XML
- بعد تسجيل XML الفاتورة الأساسي تستطيع استدعاءات AddPDFA3AssociatedFile اللاحقة إضافة مستندات داعمة؛ افحص FacturXWarnings للتحذيرات غير القاتلة المتعلقة بـ MIME type عندما تكون هذه المرفقات خارج تنسيقات المستندات الداعمة الموصى بها
- تتضمن حزمة XMP المولدة مخطط PDF/A extension الخاص بالملف التعريفي إضافة إلى حقول DocumentType وDocumentFileName وVersion وConformanceLevel ضمن namespace الفاتورة المطابق
- لا تضبط CustomXMP عند استخدام هذا المساعد، لأن حزمة XMP المقدمة من المستدعي ستستبدل metadata الفاتورة المولدة
- يمكن إرفاق XML فاتورة أساسي واحد فقط عبر هذا المساعد ضمن مسار عمل المستند
واجهات برمجة التطبيقات ذات الصلة
- THotPDF.AddPDFA3AssociatedFile Method
- THotPDF.FacturXWarnings Property
- THotPDF.AddPDFAOutputIntent Method
- THotPDF.PDFACompliance Property