Batch script to show day of the year?
Posted: 25 May 2008 09:11
Any ideas(simpler) to calculate day of the year?
What I can come up so far is to:
1. use 'map and lookup' idea by creating a string which maps the month to total number of days in previous month like:
set days=01-00;02-31;03-59;04-90 ...
2. add the resulting value from month to the day value
3. adjust the result by checking whether it is leap year or not
-Frank
What I can come up so far is to:
1. use 'map and lookup' idea by creating a string which maps the month to total number of days in previous month like:
set days=01-00;02-31;03-59;04-90 ...
2. add the resulting value from month to the day value
3. adjust the result by checking whether it is leap year or not
-Frank