Import parts, patterns, boards - stand alone

 

Using program Import services with other systems via the command line or a batch file

 

Use the program: IMPORT

 

IMPORT [filename] [/FORMAT:nn] [/OVERWRITE] [/RENAME] [/DELETE] [/NOWRTBRD] [/UDF] [/SEP][/UTF8|UTF16LE]

 

filename  - path and name of the file to import

 

Format

 

Set the import type.

 

/FORMAT:nn

 

The import types for parts and boards are as follows:-

 

0 - Part list order - ASCII/Unicode CSV (PNX)

1 - Cabinet Vision format

2 - Product Planner format

3 - Code and quantity - ASCII/Unicode CSV (PNX)

4 - Batch - part list order (BTX & PNX)

5 - Batch - Code and quantity (BTX & PNX)

6 - User defined order - ASCII/Unicode CSV (PNX)

7 - Batch - user defined order (BTX)

8 - Parts & boards - ASCII/Unicode CSV (PTX)

9 - Parts & boards - Access (MDB)

 

10 - Cut Planner format

11 - MSS/Keytrix format

12 - Giben Optisave AC & AD files

13 - Pattern exchange - ASCII/Unicode CSV (PTX)

14 - Pattern exchange - Access (MDB)

15 - Giben Optisave - AC file only

 

16 - BDX format

17 - Board list - User defined order ASCII/Unciode CSV

 

20 - XLS parts

21 - XLSX parts

30 - XLS boards

31 - XLSX boards

 

For example:

 

IMPORT c:\importdir\files\parts.pnx /FORMAT:3

IMPORT jobs.ptx /FORMAT:13

 

When using /FORMAT the program runs in silent mode (same as /AUTO) and any errors are sent to a .ERR file.

 

Delete

 

Delete original files

 

/DELETE

 

Overwrite

 

Overwrite or replace existing files

 

/OVERWRITE

 

Only applies to types 12 and 15. /OVERWRITE command means overwrite all existing files. 

 

Rename

 

/RENAME

 

Batch name is allocated a unique number from the same series as quotes/requirements (sonumber.ctl). The part list names are created by using the first five digits of the batch number and the first 3 characters of the job list name.

 

e.g RXJOB.PTX contains jobs WRK and NST

 

IMPORT RXJOB.PTX /RENAME /PARTS /AUTO

 

Batch file created:-

 

    00004.BTC

       00004WRK.PRL

       00004NST.PRL

 

It is important to ensure that, when using this option, the first three characters of each job name are unique within that PTX file. You cannot have, for example, 'RXA10' and 'RXA15' as job names unless these are placed in separate PTX files. 

 

Silent

 

Run without prompts etc.

 

/AUTO

 

Alternative commands

 

/PARTS /BOARDS /PATTERNS

 

These commands can be used as an alternative to the FORMAT command. When using these commands the relevant import parameter is used for the import format and the System parameter:Path for import data must be set

 

Errors - When you work with a command like '/AUTO' so that a program runs in 'silent' mode this means that the usual method of reporting errors is not available because the on-screen list of errors cannot be displayed. Any errors are stored in the file IMPORT.ERR

 

Delete product requirement import files - these can be deleted after import. This is done at the Import - Requirements dialog box. Check the box 'Delete files after import'.

 

Import files can also be deleted when running the program in the stand-alone mode. Use argument /DELETE to give the command line:

 

PRODIMP.EXE ["file name.ext"] [/AUTO] [/DELETE]

 

Omit /DELETE if deletion is not required

Quotation marks are not needed if the file name does not contain spaces

Use /AUTO for stand-alone operation.

 

User defined

 

/UDF

 

Where there is an import parameter for user defined parts or boards the parameter file can be specified on the command line with the UDF option.

 

IMPORT.EXE TESTFILE.IMP /FORMAT:6 /UDF:Myparts

 

Where the file name includes spaces the name must be enclosed in quotes.

 

IMPORT.EXE TESTFILE.IMP /FORMAT:6 /UDF:"My parts"

 

The /UDF argument only applies if /FORMAT:6 or /FORMAT:7 are also set.

 

Separator

 

/SEP:<separator>

 

Specify the separator for the file. e.g.

 

/SEP:58

/SEP:":"

 

The separator is either the decimal ASCII number or the character enclosed in quotes

 

The separator can be any ASCII code between 32 and 127 except the following (0 to 9, A to Z or a to z).

 

If the separator is not valid an error is reported.

 

Existing board list

 

/NOWRTBRD

 

Only applies to part list import

 

Stops the program deleting the existing board list - this allows the program to re-use a board list.

 

Unicode encoding

 

/UFT8

 

/UFT16LE

 

This allows the unicode format to set to either UTF8 or UTF16LE.

 

e.g. IMPORT c:\importdir\files\parts.pnx /FORMAT:3 /UTF-8

 

 

See also