Import a Text File
Posted on 1998-03-02
I am becoming really frustrated with this problem. I'm trying to import a comma separated, variable length text file with Field Names in the first line into a paradox/dbase table that doesn't already exist. The schema file will NOT exist before the import process. I can't believe this is so dificult someone hasn't some up with a simple set of code to do this. I've tried the Borland newsgroups, torry's, Deli. DSP, etc. all with no luck. As long as the solution handles the above, is free/freeware and doesn't require the maker's dialog boxes (I've built my own), I'll be happy.
I already have a set of functions that get me about 80% of the way, by creating the sch file then opening the table. The exception occurs when field names are used on number fields. For example, "Age" would appear on the first line and all values who be n (integer). The BDE assumes that since the Age 'field' is of integer type, 'Age' itself is an integer. Once open in executed on the table, it crashes (Age isn't an number). I can send anyone what I have already or you can some up with a better working solution.
I will increase the points if necessary. Thanks.