How to? Different ways to calculate Difference in Days...

  • This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn more.
One method to calculate the Difference in Days is with the @days function from the the ISO8601 Plugin, available from

From the ISO8601.CHM file;

echo Only %@days[T,%@nextdate[12,25]] days until Christmas!
echo %@days[T,%@easter[*]] days until Easter.

Another method is to use the DateDiff function from VBScript;

@echo off
text > vbDateDiff.vbs
shell.writeln(DateDiff("d", Now, "12/25/2013"))
if exist vbDateDiff.vbs script vbDateDiff.vbs
if exist vbDateDiff.vbs del vbDateDiff.vbs > nul

Another method is to use the @DAYSDIFF function from the FedUtils plugin, available from

echo %@DAYSDIFF[%_ISODATE,2012-12-25]
Some other examples can be found at;

Share your method on how you calculate the Difference in Days.