Print Page | Close Window

Header.basecolor in monthview

Printed From: Codejock Forums
Category: Codejock Products
Forum Name: Calendar
Forum Description: Topics Related to Codejock Calendar
URL: http://forum.codejock.com/forum_posts.asp?TID=15426
Printed Date: 20 July 2025 at 1:49am
Software Version: Web Wiz Forums 12.04 - http://www.webwizforums.com


Topic: Header.basecolor in monthview
Posted By: guru4
Subject: Header.basecolor in monthview
Date Posted: 23 October 2009 at 4:42am
How can I color some header in monthview?
Dayview and weekview I solved with the first part.
When I make same same with the Monthview all the Monthheader will get red.
Problebly the wrong event?


If eObjType = CalendarBeforeDrawThemeObject.xtpCalendarBeforeDraw_DayViewDay Then
   If isSperrtag(DrawParams.Date) Then
      pTheme2007.DayView.Day.Header.BaseColor = vbRed
   End If
ElseIf eObjType = CalendarBeforeDrawThemeObject.xtpCalendarBeforeDraw_MonthViewDay Then
   If isSperrtag(DrawParams.Date) Then
      pTheme2007.MonthView.Day.Header.BaseColor = vbRed
   End If
End If

Thanks



Replies:
Posted By: SuperMario
Date Posted: 13 November 2009 at 11:12am
Did you try xtpCalendarBeforeDraw_MonthViewWeekDayHeader or xtpCalendarBeforeDraw_MonthViewWeekHeader?


Posted By: guru4
Date Posted: 25 November 2009 at 5:24am
No that doesn't solves the problem. I know now the events sequenc of your control:

1. Weekheaders 1-4
2. WeekDay 1-7
3. Day: FROM 29.11.2009 - 26.10.2009 DESC evereytime when I move the cursor!!!!!!

My Problem is: I want to color the header for example christmas on 25.12.2009. In Weekview no problem.

Thanks for help!



Posted By: guru4
Date Posted: 16 December 2009 at 4:33am
I have solved the problem by not color the header, but the background of the day.

' Bei Tages- oder Wochenansicht
' *****************************
If eObjType = CalendarBeforeDrawThemeObject.xtpCalendarBeforeDraw_DayViewDay Then
   If isSperrtag(DrawParams.Date) Then
      pTheme2007.DayView.Day.Header.BaseColor = vbRed
   End If
  
' Bei Monatsansicht
' *****************
ElseIf eObjType = CalendarBeforeDrawThemeObject.xtpCalendarBeforeDraw_MonthViewDay Then
   If isSperrtag(DrawParams.Date) Then
      pTheme2007.MonthView.Day.BackgroundLightColor = 13095160
      pTheme2007.MonthView.Day.BackgroundSelectedColor = vbRed
   End If
End If



Print Page | Close Window

Forum Software by Web Wiz Forums® version 12.04 - http://www.webwizforums.com
Copyright ©2001-2021 Web Wiz Ltd. - https://www.webwiz.net