See first Import Invoices Example.
Other Line Types are used to import data in to sub-objects. The InInvoiceData sub-objects are:
To add Line Type tabs, click
Add Line Type (Alt+Y) on the Import Designer - Definition tab.
Code in the Definition tab calls the LineType tab code with the ProcessLineType(x) function, such as ProcessLineType(2).
If you select First Line Contains Headers on the Definition tab, you can import the field names from the file. Click the
Add Fields button. (This is not available for ASCII files.) You will be prompted to enter the line number that contains the headers for this line type. Your input file can contain several header records. Alternately, you can enter the fields and offsets.
Use the InInvoiceData Documentation for a list of properties in each sub-object. Click the + next to property Sub-Object to see the properties of the sub-object, for example, property Line to see the Line sub-object properties. Use this to map fields from the Input file to the sub-object properties.
Enter code in the Line Type tab to set the sub-object properties to mapped fields from the Input file, similarly to Import Invoices Example - Line Type 1 tab.
Ensure all required fields are set, and that all relevant fields in the Import file are mapped and set.
After setting all the fields, save the sub-object. In the example Invoice Import, for the Line sub-object (Line Type 2) the code is:
Line.Save