aspose file tools
The moose likes Beginning Java and the fly likes Convert milliseconds to seconds Big Moose Saloon
  Search | Java FAQ | Recent Topics
Register / Login
JavaRanch » Java Forums » Java » Beginning Java
Reply Bookmark "Convert milliseconds to seconds" Watch "Convert milliseconds to seconds" New topic
Author

Convert milliseconds to seconds

Chris Ramsey
Ranch Hand

Joined: Sep 15, 2003
Posts: 34
Does anyone have a method that will convert milliseconds into seconds?
Thanks.
Michael Ernest
High Plains Drifter
Sheriff

Joined: Oct 25, 2000
Posts: 7292

I usually multiply by 1000.


Make visible what, without you, might perhaps never have been seen.
- Robert Bresson
Jim Yingst
Wanderer
Sheriff

Joined: Jan 30, 2000
Posts: 18670
Or divide by 1000. I'm sure it's one of those.


"I'm not back." - Bill Harding, Twister
Ernest Friedman-Hill
author and iconoclast
Marshal

Joined: Jul 08, 2003
Posts: 24049
    
  13

Multiply by 1,000,000, then divide by 1,000,000,000. Be careful of overflow.


[Jess in Action][AskingGoodQuestions]
Chris Ramsey
Ranch Hand

Joined: Sep 15, 2003
Posts: 34
Thank you all,
Like this?

[ December 13, 2003: Message edited by: Chris Ramsey ]
Ernest Friedman-Hill
author and iconoclast
Marshal

Joined: Jul 08, 2003
Posts: 24049
    
  13

Yep!
 
I agree. Here's the link: http://zeroturnaround.com/jrebel - it saves me about five hours per week
 
subject: Convert milliseconds to seconds
 
Similar Threads
Dates Difference
stacks
DATE/TIME
compute duration in seconds
averaging time component of a calendar object