PreviousNext
Help > Programming with LAUNCHER Office > LNCCMD commands > Commands list > PDFORDERX command
PDFORDERX command

Allows you to create a Order-X electronic order.

Based on Factur-X, Order-X is a Franco-German standard for mixed electronic order, based on a PDF file (PDF/A3 standard) representing the original order and including a structured data file (XML).

 

Syntax

 

CHGVAR

VAR(&CMD) VALUE('PDFORDERX')

CHGVAR

VAR(&PARM1) VALUE('
PDF="Complete path of the PDF/A3 file"
;Xml="Complete path of the XML file"

;XMP=" Complete path of the XMP file"

;RelationShip="value";

;Description="Order-X description";

;OrderX="Complete path of the Order-X file"
')

CHGVAR

VAR(&PARM2) VALUE(' ')

CALL

PGM(LNCCMD) PARM(&HANDLE &CMD &OPT &PARM1 +

&PARM2 &RESULT)

 

 

Parameters

 

 

Parameters

 

Parm1
ou
Parm2

PDF: Complete path of the PDF/A3 file,

 

Xml: Complete path of the XML file.

 

XMP : Path of the XML file containing the XMP Meta data of the PDF/A.

 

RelationShip : Data relationship between the attached XML file and the PDF/A. Can take one of the following values (be careful to respect case): Data, Source, Alternative.

 

Description : Order-X description.

 

OrderX: Complete path of the Order-X file to save.

 

 

 

Note

If you want to create the PDF/A3 from a Word document, you can use the WSAVEAS command with Format=PDF and PdfA=true.

See the following example

Example

 

 PGM                                                     

                                                         

 DCL        VAR(&FILE) TYPE(*CHAR) LEN(2000)             

 DCL        VAR(&PATH) TYPE(*CHAR) LEN(2000)             

                                                         

 CHGVAR     VAR(&PATH) VALUE('C:\temp\5')           

 CHGVAR     VAR(&FILE) VALUE('order.docx')                

 LNCOPEN    SVRADDR('*DEV')                              

 LNCCMD     CMD(WORDOPEN)                                

                                                         

 LNCCMD     CMD(WOPENFILE) PARM1('File="' *TCAT &PATH +  

              *TCAT '\' *TCAT &FILE *TCAT '"')           

 LNCCMD     CMD(WSAVEAS) +                               

              PARM1('File="C:\temp\5\Doc.pdf";Forma+

              t=PDF;PdfA=true')                          

 LNCCMD     CMD(WORDCLOSE) PARM1('SAVE=FALSE')           

  LNCCMD     CMD(PDFORDERX) +                                
              PARM1('PDF="C:\temp\5\Doc+ 
              .pdf";Xml="C:\temp\5\or+ 
              der-x.xml";OrderX="C:\temp+ 
              \5\res.PDF";DESCRIPTION="AURA +     
              ORDER-X";RELATIONSHIP="Data";XMP="C:\temp+ 
              \5\metadata_2024.xml+ 
              "')                                                           
                                                          

 LNCCLOSE                                                

 ENDPGM