Calculating Time Difference in Batch
It’s quite nice, but the milliseconds are not …
SamKook -
It’s quite nice, but the milliseconds are not calculated.
… and it’s less nice now since it doesn’…
SamKook -
… and it’s less nice now since it doesn’t calculate task over an hour long properly it seems.
:: format with leading zeroes if %DiffMS% LSS 10 s…
sphinx02 -
:: format with leading zeroes
if %DiffMS% LSS 10 set DiffMS=0%DiffMS!%
if %DiffSec% LSS 10 set DiffMS=0%DiffSec%
if %DiffMin% LSS 10 set DiffMS=0%DiffMin%
if %DiffHrs% LSS 10 set DiffMS=0%DiffHrs%
Is OBVIOUS wrong instead it must be:
:: format with leading zeroes
if %DiffMS% LSS 10 set DiffMS=0%DiffMS!%
if %DiffSec% LSS 10 set DiffSec=0%DiffSec%
if %DiffMin% LSS 10 set DiffMin=0%DiffMin%
if %DiffHrs% LSS 10 set DiffHrs=0%DiffHrs%
That SHOULD declare the two other comments ;)
But thank you for the rest of the code…
good script to calculate time
good script to calculate time
Comments