Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations dencom on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Crystal Reports formula

Status
Not open for further replies.

keeno

MIS
Feb 24, 2006
33
GB
Hi,

I am after a formula that will identify any records with a start/end date across a 96hr period (4 days).

Any help on this matter would be greatly appreciated.

Thanks

Keeno
 
Keeno

This isn't a lot of information, what version are you on?

Did you want a parameter for someone to choose a start/end date or did you want to go against a specific date field?

Dateadd("d", 4,{datefield}) will add 4 days to date or if you prefer in hours:

DateAdd ("h",96, {datefield})

 
Sorry we are running Crystal Version 9. What I am looking for is:

START DATE or END DATE is in the next 4 days.

Thanks

David
 
If you mean the next 4 days from the current hour, then use:

{table.date} in currentdatetime to dateadd("h",96,currentdatetime)

If you mean starting tomorrow, then use:

{table.date} in currentdate+1 to currentdate+4

-LB
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top