OCP 2.8 Data Formats

Output OCP needs to interface to real world data. Often, this means that large cutting lists are best handled by exporting the data from OCP into other applications which format or sort the data for particular purposes.

OCP  exports a cutting list in a comma delimited file format which can be read by popular database and spreadsheet programs.

Input The KEYBOARD may be used to type in both stock and cutting data.

A comma delimited ASCII file can also be used to enter stock, order and cutting list data. These files may be created by a 3rd party program,  word processor, database or spreadsheet program.  Consecutive delimiters are treated as a single delimiter.  The first line in the cut and stock data files is for the field definitions and is free form text.  Length is in decimal feet, decimal inches or millimeters.  You may use a text editor to generated a cut file by using the format below with a file extension of *.cut.   Do the same for the stock (*.stk) file is.  The stock file must have the same name as the cut file with the exception of the extension which has to be *.stk instead of *.cut.  The material designated in the cut file must match the material designated in the stock file.
 

Note:   Be sure to bracket the line items in the data files with double "quotation" marks.

__________________

Example cut file:  jobname.cut  in metric units

MARK,        MATERIAL,  QTY,    LENGTH
X8B61-1003,   C100*50,   2,    1538

where MATERIAL is the type of material and is used to group material for cutting.
__________________

Example stock file:  jobname.stk 

MARK(BIN), MATERIAL, QTY, LENGTH
0001, C100*50, 1, 5245

Note: A QTY of zero (0) means there is no stock on hand so this length will be included in the order list.

Note: The units of length are interpreted according to the units setting within the OCP Program Settings menu.

Command Line Interface for batch processing Command Line

>ocp.exe  cut_file.cut  stock_file.stk  output_file.txt  shape  kerf

where each parameter is separated by a space:

cut_file = cut filename including path
stock_file.stk = stock filename including path
output_file.txt = output cutting list filename (File path is specified in the OCP Settings dialog box)
shape = material description.  This must match a Material description within the stock and cut files. No spaces are allowed in the description.
kerf = length of material lost due to cutting

Example Batch File 'OCP.bat'
 

@ECHO OFF
Rem Generated on 6/19/2001
Rem Batch program that uses OCP.exe to optimize ordering and cutting
Rem Use:
Rem >ocp.exe cut_file stock_file output_file section kerf
Rem
Rem
path %path%;C:\Program Files\OCP\;
@ECHO ON
ocp.exe mycuts.cut mystock.stk W30x148_A572-42.txt W30x148_A572-42 0
ocp.exe mycuts.cut mystock.stk W30x148_A572-50.txt W30x148_A572-50 0
 

OCP will process the batch file.  As shown, repeated batch calls to OCP.exe with different shapes can process different shapes within the same stock and cut files.

Export  file

  1. File name: output_file.txt specifies the file name that will contain the cutting results.  Its directory is specified in the OCP program settings menu.  The default location is:  'C:\Program Files\ocp'  
  2. First line contains the fields names separated by commas
  3. Subsequent lines contain cutting information in comma delimited form (example shows units in millimeters)
"Status,  Stock(Bin#), Material,  Length,  Mark,  Cut"

Examples of output lines:

INVENTORY,  1, UB254*102*22,  6000,  6B11-1019 ,5878
NON-INVENTORY,  2, UB254*102*22,  6000,  6B11-1019 ,5878
SCRAP,  1, UB254*102*22,  900

Example Batch Files

Click here.  Choose open. Choose Unzip.  A sample ocp.bat,  mycuts.cut and mystock.stk will be saved to the 'C:\Program Files\OCP' folder.  Open the OCP.bat file to run the batch program and create two cutting files - one for each material.






Copyright © 2008  SoftLogix, Inc.  All Rights Reserved.
Windows® XP and Windows Vista are trademarks of Microsoft Corporation. SteelLogic is a registered trademark of Computer Detailing Corporation.  WinEstimator is a registered trademark of WinEstimator, Inc

Updated 18-JUL-2008