Page Index Toggle Pages: 1 Send TopicPrint
Normal Topic weekrange sat/sun at start of row??? (Read 5447 times)
Anna
YaBB Newbies
*
Offline


I love YaBB 1G - SP1!

Posts: 4
Joined: Mar 20th, 2007
weekrange sat/sun at start of row???
Mar 20th, 2007 at 2:41am
Print Post  
Hi,

I'm not sure what i've done, but my weekrange view is displaying sat/sun at the start of the row.
I'm setting my calendar.date = now()
and calendar.enddate to be the last day of the week (the sunday)
In the weekrangesettings i'm setting the viewstyle to be weekperrow and visiblerows = 1.
It is showing one week in a row starting on saturday then the next row is showing the sat/sun after that.

Any ideas? does it matter that the dates i'm using have times in them?

Thanks,
Anna
  
Back to top
 
IP Logged
 
Meppy
God Member
*****
Offline


MindFusion support

Posts: 1783
Joined: Jul 20th, 2005
Re: weekrange sat/sun at start of row???
Reply #1 - Mar 20th, 2007 at 5:10am
Print Post  
I presume you want to display the days of one week in a single row, starting from a random day of the week and ending at Sunday. To achieve this, you have to specify that Monday is the first day of the week. The following code demonstrates how to do this:

Code
Select All
calendar1.BeginInit();
calendar1.DateTimeFormat.FirstDayOfWeek = DayOfWeek.Monday;
calendar1.EndInit(); 



The BeginInit and EndInit calls are required so that the calendar updates its internal structures appropriately in response to this change.

Meppy
  
Back to top
 
IP Logged
 
Anna
YaBB Newbies
*
Offline


I love YaBB 1G - SP1!

Posts: 4
Joined: Mar 20th, 2007
Re: weekrange sat/sun at start of row???
Reply #2 - Mar 20th, 2007 at 7:20pm
Print Post  
Great, thanks Cheesy
That was the setting I was looking for but couln't find.

Is there a way to adjust the height of the day cells to fill the whole screen. At the moment they are only taking up 1/2 of it? But i'd prefer to only show 1 row/week at a time.
Here is a picture of what it currently looks like.


Also, Is there a list of the settings that need to be set within the begininit and endinit tags?

Cheers,
Anna
  
Back to top
 
IP Logged
 
Meppy
God Member
*****
Offline


MindFusion support

Posts: 1783
Joined: Jul 20th, 2005
Re: weekrange sat/sun at start of row???
Reply #3 - Mar 21st, 2007 at 4:49am
Print Post  
You probably need to set the number of visible rows to 1.

Code
Select All
calendar1.WeekRangeSettings.VisibleRows = 1; 


Meppy
  
Back to top
 
IP Logged
 
Meppy
God Member
*****
Offline


MindFusion support

Posts: 1783
Joined: Jul 20th, 2005
Re: weekrange sat/sun at start of row???
Reply #4 - Mar 21st, 2007 at 5:04am
Print Post  
You can set various properties withing BeginInit and EndInit block. There are no required or needed properties if that's what you are asking. The reason to encase initialization code in these methods is to avoid unnecessary invalidation of the control's internal structure on each property assignment. Once the EndInit method is called, the control updates itself taking into consideration all changes made to its properties.

Meppy
  
Back to top
 
IP Logged
 
Anna
YaBB Newbies
*
Offline


I love YaBB 1G - SP1!

Posts: 4
Joined: Mar 20th, 2007
Re: weekrange sat/sun at start of row???
Reply #5 - Mar 26th, 2007 at 3:53am
Print Post  
Thanks, That was it!
  
Back to top
 
IP Logged
 
Page Index Toggle Pages: 1
Send TopicPrint