Link to home
Start Free TrialLog in
Avatar of sluggo050499
sluggo050499

asked on

Import File with FSO Date and Time

I am currently writing a macro to import a file.  I want to append the file date/time with each record.  This way, I can prequery the data table and stop the file from being imported more than once.

Thanks,
Doug
Avatar of Jim Dettman (EE MVE)
Jim Dettman (EE MVE)
Flag of United States of America image

Just open the table that your appending to in design mode and on your date/time field, set the default to Date() or Now() (if you need the time).

Jim.
Or are your creating a brand new table?

Jim.
Avatar of sluggo050499
sluggo050499

ASKER

I will be appending the data to an existing table.  The field for the date & time on the file will be in a field called 'filedate'.
Then just set the default value for FileDate to Now() or Date().  It will be filled in automatically as soon as the record is appended.

Jim.
FSO=File System Object.  Part of the FSO is the creation date and time.  That's what I need to import.  Not the Now() or Date().

Thanks
ASKER CERTIFIED SOLUTION
Avatar of Jim Dettman (EE MVE)
Jim Dettman (EE MVE)
Flag of United States of America image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial