I'm guessing you are not using the latest version of Date::Manip 6.46. You could try
$delta=Delta_Format(DateCalc($start_date_parsed,$end_date_pa
+rsed),'',"%dt"); # changed from %dv
but if you did upgrade you could use the OO interface like this
use strict;
use Date::Manip;
my $start_date = '8/4/2014';
my $end_date = '8/15/2014';
print "$start_date to $end_date \n";
my $date1 = new Date::Manip::Date;
my $date2 = $date1->new_date();
my $err1 = $date1->parse($start_date);
my $err2 = $date2->parse($end_date);
while ($date1->cmp($date2) <= 0) {
print $date1->printf("%m-%d-%Y")."\n";
$date1->next_business_day(1);
}
poj
Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
Read Where should I post X? if you're not absolutely sure you're posting in the right place.
Please read these before you post! —
Posts may use any of the Perl Monks Approved HTML tags:
- a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
| |
For: |
|
Use: |
| & | | & |
| < | | < |
| > | | > |
| [ | | [ |
| ] | | ] |
Link using PerlMonks shortcuts! What shortcuts can I use for linking?
See Writeup Formatting Tips and other pages linked from there for more info.