Technical Questions
 Crystal Reports Forum : Crystal Reports 9 through 2022 : Technical Questions
Message Icon Topic: FirstDayOfWeek Post Reply Post New Topic
Author Message
Randy
Newbie
Newbie


Joined: 29 Mar 2010
Location: United States
Online Status: Offline
Posts: 2
Quote Randy Replybullet Topic: FirstDayOfWeek
     Posted: 29 Mar 2010 at 10:24am
I need to group and print a report on the end of the week of a given date and I need to change the end of the week from the default day of Saturday to Friday.
 
I think I need to use the FirstDayOfWeek function to change from Saturday to Friday.
 
My problem is passing that to the report group.
 
I have tried using a date formula, however, when I use the group options the option of printing the section for each week is not available on a formula field.
IP IP Logged
DBlank
Moderator
Moderator


Joined: 19 Dec 2008
Online Status: Offline
Posts: 9053
Quote DBlank Replybullet Posted: 29 Mar 2010 at 11:38am
Not sure how to adjust the week function in the group. I guess you could just 'trick' it by using a formula field to add 1 day to your date field and then group on that formula field instead. Your default group headers would be off so you would need to fix those too but logically I think that this would work...
dateadd('d',1,{Table.Date})


Edited by DBlank - 29 Mar 2010 at 11:39am
IP IP Logged
Randy
Newbie
Newbie


Joined: 29 Mar 2010
Location: United States
Online Status: Offline
Posts: 2
Quote Randy Replybullet Posted: 30 Mar 2010 at 1:25am

That worked perfectly.  Thanks for the quick response.

IP IP Logged
Printable version Printable version

Forum Jump
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot delete your posts in this forum
You cannot edit your posts in this forum
You cannot create polls in this forum
You cannot vote in polls in this forum