PDA

Click to See Complete Forum and Search --> : Writing a filename to a database!!! Please Help!!!


kanejone
Nov 22nd, 2000, 04:21 AM
Hi guys,

I have a load of file in a directory. How do I write all of the file names that are contained in that folder and all subfolders to a database table. Thanks for any help that anyone may be able to offer.

Cheers
JK

paulw
Nov 22nd, 2000, 05:49 AM
You can retrieve filenames by using the Dir function which will return a string. To access the subdirectories, check the attributes of each dir entry for vbDirectory. Add these to an array and use the Dir function in a loop with recursion.

Check out Dir in the VB help, its got some pretty good examples.

P.

kanejone
Nov 22nd, 2000, 06:03 AM
Thanks a lot for the help.
Cheers
JK