CSV 2 INClude file

   
CSV2INC is a utility program that uses the names in a CSV file header line to create a Comet INCLUDE file.

The program runs in two phases. The first phase collects the names from the header line in the CSV file, removes charactors in the names that would interfer with using the name as a variable name in Internet Basic (space, underline, @ and #) . Then CSV2INC attempts to determine if the field is a string or a number. It uses a text file names CSV2INC.TXT. This file can (and should) be updated as you learn about the way fields are named in the CSV files you work with.

Phase one asks for the name of the CSV file. The CSV file must be in a configured Comet directory but does not have to be in the QDIR for that directory as CSV2INC will add it.

CSV2INC puts the variable names into a temporary text file and launches your text editor. Variables that seem to be strings have the required $; of course numbers do not. You should carefully examine the variable names and your actual file and add or remove $ as needed. Then you must save the corrected file, exit your text editor and return to CSV2INC. The program reads the text file and creates an INCLUDE file and launches your text editor to verify.