× The internal search function is temporarily non-functional. The current search engine is no longer viable and we are researching alternatives.
As a stop gap measure, we are using Google's custom search engine service.
If you know of an easy to use, open source, search engine ... please contact support@midrange.com.


  • Subject: RE: File.setLastModified()
  • From: "Clapham, Paul" <pclapham@xxxxxxxxxxxxx>
  • Date: Tue, 3 Apr 2001 10:03:53 -0700

Title: File.setLastModified()
According to the java documentation, setLastModified() returns true if it succeeded and false if it failed.  What does it return in your case?  Also, what operating system are you running this under, and why do you need "-Djava.version=1.2"?
 
PC2
-----Original Message-----
From: Thierry Bernard [mailto:tbernard@informatech.com]
Sent: April 3, 2001 06:59
To: 'JAVA400-L-DIGEST@midrange.com'
Subject: File.setLastModified()

// insure an even number of seconds (round down)                
  long newTime = ficTime - (( (ficTime / 1000) % 2 ) * 1000 );  
  Date newDate = new Date( newTime) ;                           
  System.out.println( newDate.toString() ) ;                    
  System.out.println( newTime ) ;                               
  aFile.setLastModified( newTime ) ;                           
                                                                
$                                         
java -Djava.version=1.2 EvenTime test.txt 
Mon Apr 02 19:23:05 GMT+00:00 2001        
986239385000                              
Mon Apr 02 19:23:04 GMT+00:00 2001        
986239384000                              
Thu Jan 01 00:00:00 GMT+00:00 1970        
0                                         

 


As an Amazon Associate we earn from qualifying purchases.

This thread ...


Follow On AppleNews
Return to Archive home page | Return to MIDRANGE.COM home page

This mailing list archive is Copyright 1997-2024 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].

Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.