470,632 Members | 1,993 Online
Bytes | Developer Community
New Post

Home Posts Topics Members FAQ

Post your question to a community of 470,632 developers. It's quick & easy.

File Creation Time

SK
I have a file. i get the creation time using
File.GetCreationTime. then i go and delete that file. and
then create it again and print the File.GetCreationTime.
It is giving me the old creation time itself...y is it
so..?

Jul 21 '05 #1
3 2110
> I have a file. i get the creation time using
File.GetCreationTime. then i go and delete that file. and
then create it again and print the File.GetCreationTime.
It is giving me the old creation time itself...y is it
so..?


normally not.

--
cody

[Freeware, Games and Humor]
www.deutronium.de.vu || www.deutronium.tk
Jul 21 '05 #2
sk
it would be better if u try it out and give an answer.

-----Original Message-----
I have a file. i get the creation time using
File.GetCreationTime. then i go and delete that file. and then create it again and print the File.GetCreationTime.
It is giving me the old creation time itself...y is it
so..?


normally not.

--
cody

[Freeware, Games and Humor]
www.deutronium.de.vu || www.deutronium.tk
.

Jul 21 '05 #3
Hi,

The behaviour you see is the operating system behaviour and I belive you
can see it only for the file names less than 8.3 chars long.
In order to prevent long file name losses when old applications operate the
files using short files names (8.3), the operating system tracks
delete/create operations, and if an app creates a file with the name same
as a short name of recently deleted file, the OS assumes this is the same
file. It assigns back the long name and the creation time. Although your
application is a .Net application that supports long file names, in your
case you probably try to create a file with name not longer than 8 chars
and extension not longer than 3 chars. I.e. from OS point of view it looks
like an old file name format.

--
Victor Urnyshev [MSFT]
This post is "AS IS" with no warranties, and confers no rights.
--------------------
|From: "cody" <pl*************************@gmx.de>
|References: <cd****************************@phx.gbl>
|Subject: Re: File Creation Time
|Date: Wed, 25 Aug 2004 23:51:45 +0200
|Lines: 15
|X-Priority: 3
|X-MSMail-Priority: Normal
|X-Newsreader: Microsoft Outlook Express 6.00.2800.1437
|X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2800.1441
|Message-ID: <#T**************@tk2msftngp13.phx.gbl>
|Newsgroups: microsoft.public.dotnet.general
|NNTP-Posting-Host: p50909CBB.dip.t-dialin.net 80.144.156.187
|Path:
cpmsftngxa10.phx.gbl!TK2MSFTNGXS01.phx.gbl!cpmsftn gxa06.phx.gbl!TK2MSFTNGP08
phx.gbl!tk2msftngp13.phx.gbl
|Xref: cpmsftngxa10.phx.gbl microsoft.public.dotnet.general:143658
|X-Tomcat-NG: microsoft.public.dotnet.general
|
|> I have a file. i get the creation time using
|> File.GetCreationTime. then i go and delete that file. and
|> then create it again and print the File.GetCreationTime.
|> It is giving me the old creation time itself...y is it
|> so..?
|
|normally not.
|
|--
|cody
|
|[Freeware, Games and Humor]
|www.deutronium.de.vu || www.deutronium.tk
|
|
|

Jul 21 '05 #4

This discussion thread is closed

Replies have been disabled for this discussion.

Similar topics

5 posts views Thread by [ EuGeNe ] | last post: by
2 posts views Thread by David Fickbohm | last post: by
2 posts views Thread by Robizzle | last post: by
4 posts views Thread by wil | last post: by
8 posts views Thread by Eddie Suey | last post: by
4 posts views Thread by SK | last post: by
6 posts views Thread by KoRnDragon | last post: by
4 posts views Thread by Carl J. Van Arsdall | last post: by
By using this site, you agree to our Privacy Policy and Terms of Use.