Cell Color in Month View |
Post Reply |
Author | |
smis
Newbie Joined: 05 January 2007 Status: Offline Points: 4 |
Post Options
Thanks(0)
Posted: 05 January 2007 at 2:14pm |
Is there any way we can change the color of a cell in the Month View. I need to have three colors to be diaplyed. Say the whole scenario is such that I want to show days for which I have no appointment in red. Days for which I am having Task assigned for the whole day to be displayed in Green and days for which I have task assigned for some hours only to be displayed in yellow.
|
|
sserge
Moderator Group Joined: 01 December 2004 Status: Offline Points: 1297 |
Post Options
Thanks(0)
|
You can do this for Office 2007 theme only. It has extra customization features. CalendarThemeOffice2007 object has many parameters like fonts, colors, sizes, etc for each Calendar object (like days, events, headers ...) Changing these parameters is applied to all objects of such type. The general idea of dynamic customization that calendar send special notification XTP_NC_CALENDAR_BEFORE_DRAW_THEMEOBJECT which allows you to change drawing parameters for each object separately. For how to use calendar notifications see: CCalendarDemoView::CCalendarDemoView() For optimization, this notification is sent only for objects which specified in BeforeDrawFlags member. When you set theme, make the following call: pTheme2007->SetBeforeDrawFlags(xtpCalendarBeforeDraw_MonthViewDay); See also: XTPCalendarBeforeDrawThemeObject enum. Example of code to set day background color:
-- WBR, Serge |
|
Post Reply | |
Tweet
|
Forum Jump | Forum Permissions 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 |