L
Lord0
Hi there,
I have an object with fields which represent dates and therefore a date
range.
private Date m_startDate;
private Date m_endDate;
Given another singular date (target) as an argument I want to return
all the days, in the range, where target.mon = dayrange.mon. Sorry for
the bad explanation. Maybe some examples:
If m_startDate is 15th Jan 06, m_endDate is 20th Mar 06 and target is
Jan 06
return: 15..31
If m_startDate is 15th Jan 06, m_endDate is 20th Mar 06 and target is
Feb 06
return 1..28[29]
If m_startDate is 15th Jan 06, m_endDate is 20th Mar 06 and target is
Mar 06
return 1..20
If m_startDate is 15th Jan 06, m_endDate is 20th Jan 06 and target is
Jan 06
return 15..20
This has fried my head and I am at a loss to think of a nice solution.
thanks in advance
Lord0
I have an object with fields which represent dates and therefore a date
range.
private Date m_startDate;
private Date m_endDate;
Given another singular date (target) as an argument I want to return
all the days, in the range, where target.mon = dayrange.mon. Sorry for
the bad explanation. Maybe some examples:
If m_startDate is 15th Jan 06, m_endDate is 20th Mar 06 and target is
Jan 06
return: 15..31
If m_startDate is 15th Jan 06, m_endDate is 20th Mar 06 and target is
Feb 06
return 1..28[29]
If m_startDate is 15th Jan 06, m_endDate is 20th Mar 06 and target is
Mar 06
return 1..20
If m_startDate is 15th Jan 06, m_endDate is 20th Jan 06 and target is
Jan 06
return 15..20
This has fried my head and I am at a loss to think of a nice solution.
thanks in advance
Lord0