[AccessD] fso.DeleteFile Strange behaviour!?

Carlos Alberto Alves caa at highway.com.br
Fri Feb 13 02:14:40 CST 2004


On Wed, 11 Feb 2004 16:55:04 -0600, <DWUTKA at marlow.com> wrote:

> What's the OS?  Windows 2000 has indexing, which indexes your files.  It 
> is
> VERY possible that indexing is causing this issue.
>
> A workaround, would be to create the new db under a different name, then
> rename it.  That should force the new Created time.
>
> Drew
>
> -----Original Message-----
> From: accessd-bounces at databaseadvisors.com
> [mailto:accessd-bounces at databaseadvisors.com]On Behalf Of S D
> Sent: Wednesday, February 11, 2004 2:01 AM
> To: accessd
> Subject: [AccessD] fso.DeleteFile Strange behaviour!?
>
>
> Hi group,
>
> I'm using FileSystemObject to delete a MDB file.
> After that I'm creating a new MDB.
> Then i'm using the .DateCreated method to get the the info about when the
> file was created. I checked this in the help: "Returns the date and time
> that the specified file or folder was created. Read-only."
>
> However the time it returns is the date\time combination of when I 
> created
> the DB for the first time.
>
> EG: I'm starting the application at 8:00. I then show on screen the
> date\time the temp (analyses) db was created, let's say that it was 
> created
> on 10 feb 2004 16:34:56. I then decide to create a new temp db. I press 
> the
> button and it deletes the file, creates a new one and adds tables to it.
> Then I show the user the .DateCreated wich shows 8:00.
> When I stay in the program and do the above at 8:15 the .DateCreated 
> method
> returns again 8:00!!! When I look in Explorer the DateCreated column 
> shows
> 8:00 and the DateModified shows 8:15?!!? QUA PASA. WHY is the date 
> created
> 8:00? I've checked in Explorer that the file is gone after the deletefile
> statement.
>
> Any ideas?

I have just written a Sub to make a backup copy of a backend and rename in 
order to have 30 copies as follows: 01_file.mdb, 02_file.mdb and so on. I 
have chosen FileCopy and Kill statements. I checked file attributes and 
have had no problems so far.
You may also opt for Name statement if you need to move instead copying a 
file.
HTH,
-- 
**************************************
* Carlos Alberto Alves               *
* Child Neurologist                  *
* Systems Analyst/Programmer         *
* Rio de Janeiro, Brazil             *
* mailto:caa at highway.com.br          *
**************************************


More information about the AccessD mailing list