Getting milliseconds into format? days HH:mm:ss.ms
Posted: Fri Apr 13, 2012 9:16 pm
Hi,
I found some code where milliseconds would be displayed in minutes and seconds... I would like to know if you can help me out with it on how to display milliseconds in days HH:mm:ss.ms?
ExposureTime (and TimeEstimate) is a value of x milliseconds...
This is what I found out already:
Any idea? ::)
Thanks in advance
I found some code where milliseconds would be displayed in minutes and seconds... I would like to know if you can help me out with it on how to display milliseconds in days HH:mm:ss.ms?
ExposureTime (and TimeEstimate) is a value of x milliseconds...
This is what I found out already:
Code: Select all
TimeEstimate = ExposureTime;
TimeEstimateDays= ________________;
TimeEstimateHours= ________________;
TimeEstimateMinutes=(TimeEstimate/1000)/60;
TimeEstimateSeconds=(TimeEstimate/1000)-(TimeEstimateMinutes*60);
TimeEstimateMilliseconds= ________________;
// days
________________;
// hours
________________;
// minutes
dummy=TimeEstimateMinutes-(int(TimeEstimateMinutes/10)*10);
// then display the minutes (the ones of it) with the value of dummy
dummy=int((TimeEstimateMinutes-dummy)/10);
// then display the minutes (the tens of it) with the value of dummy
// seconds
dummy=TimeEstimateSeconds-(int(TimeEstimateSeconds/10)*10);
// then display the seconds (the ones of it) with the value of dummy
dummy=int((TimeEstimateSeconds-dummy)/10);
// then display the seconds (the tens of it) with the value of dummy
// milliseconds (the rest that would not result into a second)
________________;
Thanks in advance