• Post Reply Bookmark Topic Watch Topic
  • New Topic

How to get the Date of creation of a File[very.... Urgent....]  RSS feed

 
netharam ram
Ranch Hand
Posts: 202
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi, I want to display the date of creation of a File.I get the last accessed date from the lastModified()method ,but I want the file creation Date.Please reply me as soon as possible.
Happy middling with java
Netharam
 
Roy Ben Ami
Ranch Hand
Posts: 732
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
if the file hasnt been modified since its creation date then it will return you the creation date.
as far as i know, if u modify the file then the cretaion date changes to the new modification.
same as in dos.
(but then again i may be wrong)
 
netharam ram
Ranch Hand
Posts: 202
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
sorry U have misunderstood my post.You might have noticed in Windows,when u right click on a file & view its properties it displays the file's creation date,last Modified Date & last accessed date.Similarly I want the file creation Date.
Netharam
 
Roy Ben Ami
Ranch Hand
Posts: 732
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
ok
did a little net searching and the answer i got is u CANT!
the reason for this is that now all platforms (including all kind of windows) have this information.
java need to support all platforms , so u cant do it.
u can try use JNI to access it.
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!