Schema.ini & file names
-
I'm trying to create a schema.ini file to impport data from a csv file and have hit a snag. According to this article - http://msdn2.microsoft.com/en-us/library/ms709353.aspx - the first line in the schema needs to be the file name. My problem is that I get uniquely named files and have no idea what they will be untill I get them. Is there a way to omit the first line in the schema or just specify the filename as *.csv ? Thanks, Nathan
-
I'm trying to create a schema.ini file to impport data from a csv file and have hit a snag. According to this article - http://msdn2.microsoft.com/en-us/library/ms709353.aspx - the first line in the schema needs to be the file name. My problem is that I get uniquely named files and have no idea what they will be untill I get them. Is there a way to omit the first line in the schema or just specify the filename as *.csv ? Thanks, Nathan
digsy_ wrote:
Is there a way to omit the first line in the schema or just specify the filename as *.csv ?
I've never used the Text driver, so.... As far as I can tell, no you can't remove this. You are probably going to have to write this file out with the name of the file you're importing for each and every file you import using this method. The alternative is to write your own import implentation from scratch or try to find a third party CSV parser class. Search the articles here for "CSV" and you should find at least one.
A guide to posting questions on CodeProject[^]
Dave Kreskowiak Microsoft MVP Visual Developer - Visual Basic
2006, 2007