<?xml version="1.0" encoding="utf-8" ?>
<?xml-stylesheet type="text/xsl" href="RSS_xslt_style.asp" version="1.0" ?>
<rss version="2.0" xmlns:WebWizForums="https://syndication.webwiz.net/rss_namespace/">
 <channel>
  <title>Codejock Developer Community : Event being drawn in BeforeDrawThemeObject</title>
  <link>http://forum.codejock.com/</link>
  <description><![CDATA[This is an XML content feed of; Codejock Developer Community : Calendar : Event being drawn in BeforeDrawThemeObject]]></description>
  <copyright>Copyright (c) 2006-2013 Web Wiz Forums - All Rights Reserved.</copyright>
  <pubDate>Tue, 28 Apr 2026 08:50:34 +0000</pubDate>
  <lastBuildDate>Mon, 20 Aug 2012 09:19:40 +0000</lastBuildDate>
  <docs>http://blogs.law.harvard.edu/tech/rss</docs>
  <generator>Web Wiz Forums 12.04</generator>
  <ttl>360</ttl>
  <WebWizForums:feedURL>forum.codejock.com/RSS_post_feed.asp?TID=13663</WebWizForums:feedURL>
  <image>
   <title><![CDATA[Codejock Developer Community]]></title>
   <url>http://forum.codejock.com/forum_images/codejock-logo.gif</url>
   <link>http://forum.codejock.com/</link>
  </image>
  <item>
   <title><![CDATA[Event being drawn in BeforeDrawThemeObject :   This code will change color...]]></title>
   <link>http://forum.codejock.com/forum_posts.asp?TID=13663&amp;PID=68777&amp;title=event-being-drawn-in-beforedrawthemeobject#68777</link>
   <description>
    <![CDATA[<strong>Author:</strong> <a href="http://forum.codejock.com/member_profile.asp?PF=369">SuperMario</a><br /><strong>Subject:</strong> 13663<br /><strong>Posted:</strong> 20 August 2012 at 9:19am<br /><br /><div>This code will change color of event if the word "Deleted" is int he subject.&nbsp; You can modify it to do as you with and check for label:</div><div></div>Private Sub CalendarControl_BeforeDrawThemeObject(ByVal eObjType As XtremeCalendarControl.CalendarBeforeDrawThemeObject, ByVal DrawParams As Variant)<br>On Error Resume Next:<br>  Dim pCell As CalendarThemeDayViewCellParams<br>    <br>  Dim pTheme2007 As CalendarThemeOffice2007<br>  Set pTheme2007 = CalendarControl.Theme<br>  <br>  Dim pEvent As CalendarEvent<br>  Set pEvent = Nothing<br>  <br>  If eObjType = xtpCalendarBeforeDraw_DayViewEvent Then<br>    Set pEvent = DrawParams.Event<br>    <br>    If InStr(pEvent.Subject, "DELETED") &gt; 0 Then<br>      pEvent.Label = 1<br>    End If<br>        <br>  End If<br>End Sub]]>
   </description>
   <pubDate>Mon, 20 Aug 2012 09:19:40 +0000</pubDate>
   <guid isPermaLink="true">http://forum.codejock.com/forum_posts.asp?TID=13663&amp;PID=68777&amp;title=event-being-drawn-in-beforedrawthemeobject#68777</guid>
  </item> 
  <item>
   <title><![CDATA[Event being drawn in BeforeDrawThemeObject : I have a similar issue.... how...]]></title>
   <link>http://forum.codejock.com/forum_posts.asp?TID=13663&amp;PID=68672&amp;title=event-being-drawn-in-beforedrawthemeobject#68672</link>
   <description>
    <![CDATA[<strong>Author:</strong> <a href="http://forum.codejock.com/member_profile.asp?PF=4533">BCS123</a><br /><strong>Subject:</strong> 13663<br /><strong>Posted:</strong> 27 July 2012 at 6:07pm<br /><br />I have a similar issue....&nbsp; how do I get the strike through&nbsp; to apply only for those events that are in dark purple only (the ones circled in red shud be regular text). Would also like to change the font color to white<img src="http://forum.codejock.com/forum_images/post_butt&#111;n_hyperlink.gif" border="0" title="Insert Hyperlink" alt="Insert Hyperlink" /> for the strike thro events.. thx<img src="uploads/4533/mthscreen.jpg" height="533" width="897" border="0" />]]>
   </description>
   <pubDate>Fri, 27 Jul 2012 18:07:00 +0000</pubDate>
   <guid isPermaLink="true">http://forum.codejock.com/forum_posts.asp?TID=13663&amp;PID=68672&amp;title=event-being-drawn-in-beforedrawthemeobject#68672</guid>
  </item> 
  <item>
   <title><![CDATA[Event being drawn in BeforeDrawThemeObject : I&amp;#039;m sorry I made that last...]]></title>
   <link>http://forum.codejock.com/forum_posts.asp?TID=13663&amp;PID=46671&amp;title=event-being-drawn-in-beforedrawthemeobject#46671</link>
   <description>
    <![CDATA[<strong>Author:</strong> <a href="http://forum.codejock.com/member_profile.asp?PF=3351">wakerunner</a><br /><strong>Subject:</strong> 13663<br /><strong>Posted:</strong> 13 March 2009 at 1:55pm<br /><br />I'm sorry I made that last post before I saw your post. That looks like what I am looking for. <DIV>&nbsp;</DIV><DIV>I knew it would be something really easy I was missing. It works perfect, thanks for the help!</DIV><DIV>&nbsp;</DIV>]]>
   </description>
   <pubDate>Fri, 13 Mar 2009 13:55:59 +0000</pubDate>
   <guid isPermaLink="true">http://forum.codejock.com/forum_posts.asp?TID=13663&amp;PID=46671&amp;title=event-being-drawn-in-beforedrawthemeobject#46671</guid>
  </item> 
  <item>
   <title><![CDATA[Event being drawn in BeforeDrawThemeObject :  I showed you if you look at...]]></title>
   <link>http://forum.codejock.com/forum_posts.asp?TID=13663&amp;PID=46670&amp;title=event-being-drawn-in-beforedrawthemeobject#46670</link>
   <description>
    <![CDATA[<strong>Author:</strong> <a href="http://forum.codejock.com/member_profile.asp?PF=369">SuperMario</a><br /><strong>Subject:</strong> 13663<br /><strong>Posted:</strong> 13 March 2009 at 1:53pm<br /><br />I showed you if you look at my code.&nbsp; use my code and mark's and you have solution.<br><br><pre ="BBcode"><div>Private Sub CalendarControl_BeforeDrawThemeObject(ByVal eObjType As XtremeCalendarControl.CalendarBeforeDrawThemeObject, ByVal Params As Variant)</div><br><div>Dim <font color="#cc0000">pEvent</font> As CalendarEvent</div><br><div>If eObjType = xtpCalendarBeforeDraw_DayViewEvent Then<br><b>     Set pEvent = Params.Event</b><br><br>&nbsp;&nbsp;&nbsp;&nbsp; if <font color="#cc0000">pEvent</font>.CustomProperties.Property("status") = "completed" then</div><br><div>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;pTheme2007.DayView.Day.Group.SingleDayEvent.Normal.Subject.Font.Strikethrough = True<br>&nbsp;&nbsp;&nbsp;&nbsp; end if</div><br><div>end if</div><br><div>End Sub <br></div></pre><br>]]>
   </description>
   <pubDate>Fri, 13 Mar 2009 13:53:27 +0000</pubDate>
   <guid isPermaLink="true">http://forum.codejock.com/forum_posts.asp?TID=13663&amp;PID=46670&amp;title=event-being-drawn-in-beforedrawthemeobject#46670</guid>
  </item> 
  <item>
   <title><![CDATA[Event being drawn in BeforeDrawThemeObject : I know that part. I don&amp;#039;t...]]></title>
   <link>http://forum.codejock.com/forum_posts.asp?TID=13663&amp;PID=46669&amp;title=event-being-drawn-in-beforedrawthemeobject#46669</link>
   <description>
    <![CDATA[<strong>Author:</strong> <a href="http://forum.codejock.com/member_profile.asp?PF=3351">wakerunner</a><br /><strong>Subject:</strong> 13663<br /><strong>Posted:</strong> 13 March 2009 at 1:47pm<br /><br />I know that part. I don't think you under stand what I am trying to do. That code will make all subjects fontstrikethrough. I only want certain events to be strikethrough, like below: <DIV>&nbsp;</DIV><DIV><table width="99%"><tr><td><pre class="BBcode">&nbsp;</DIV><DIV>Private Sub CalendarControl_BeforeDrawThemeObject(ByVal eObjType As XtremeCalendarControl.CalendarBeforeDrawThemeObject, ByVal Params As Variant)</DIV><DIV>Dim <FONT color=#cc0000>pEvent</FONT> As CalendarEvent</DIV><DIV>If eObjType = xtpCalendarBeforeDraw_DayViewEvent Then<BR>&nbsp;&nbsp;&nbsp;&nbsp; <FONT color=#33ff00><FONT color=#0000ff>if</FONT> </FONT><FONT color=#cc0000>pEvent</FONT><FONT color=#0000ff>.CustomProperties.Property("status") = "completed" then</FONT></DIV><DIV>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;pTheme2007.DayView.Day.Group.SingleDayEvent.Normal.Subject.Font.Strikethrough = True<BR>&nbsp;&nbsp;&nbsp;&nbsp; end if</DIV><DIV>end if</DIV><DIV>End Sub&nbsp;</DIV><DIV></pre></td></tr></table></DIV><DIV>&nbsp;</DIV><DIV>The question is how do I determine which CalendarEvent is being drawn each firing of the "BeforeDrawThemeObject"? How do I find or set the <FONT color=#cc0000>pEvent</FONT>?</DIV><DIV>&nbsp;</DIV><DIV>&nbsp;</DIV>]]>
   </description>
   <pubDate>Fri, 13 Mar 2009 13:47:31 +0000</pubDate>
   <guid isPermaLink="true">http://forum.codejock.com/forum_posts.asp?TID=13663&amp;PID=46669&amp;title=event-being-drawn-in-beforedrawthemeobject#46669</guid>
  </item> 
  <item>
   <title><![CDATA[Event being drawn in BeforeDrawThemeObject :   wakerunner wrote:How can you...]]></title>
   <link>http://forum.codejock.com/forum_posts.asp?TID=13663&amp;PID=46667&amp;title=event-being-drawn-in-beforedrawthemeobject#46667</link>
   <description>
    <![CDATA[<strong>Author:</strong> <a href="http://forum.codejock.com/member_profile.asp?PF=369">SuperMario</a><br /><strong>Subject:</strong> 13663<br /><strong>Posted:</strong> 13 March 2009 at 1:39pm<br /><br /><table width="99%"><tr><td class="BBquote"><img src="forum_images/quote_box.png" title="Originally posted by wakerunner" alt="Originally posted by wakerunner" style="vertical-align: text-bottom;" /> <strong>wakerunner wrote:</strong><br /><br /><div>How can you determine the event that is currently being drawn in the&nbsp;"BeforeDrawThemeObject" event?</div></td></tr></table><br><br>Pretty simple:<br><br>Set this in form load:<br>CalendarControl.BeforeDrawThemeObjectFlags = -1 ' set all<br><br>Then:<br><br>Private Sub CalendarControl_BeforeDrawThemeObject(ByVal eObjType As XtremeCalendarControl.CalendarBeforeDrawThemeObject, ByVal Params As Variant)<br>&nbsp;&nbsp; <br>&nbsp;&nbsp;&nbsp; Dim pEvent As CalendarEvent<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; <br>&nbsp;&nbsp;&nbsp; If eObjType = xtpCalendarBeforeDraw_DayViewEvent Then<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Set pEvent = Params.Event<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Debug.Print "EventID = " &amp; pEvent.Id &amp; ". Subject = " &amp; pEvent.Subject<br>&nbsp;&nbsp;&nbsp; End If<br><br>End Sub<br>]]>
   </description>
   <pubDate>Fri, 13 Mar 2009 13:39:35 +0000</pubDate>
   <guid isPermaLink="true">http://forum.codejock.com/forum_posts.asp?TID=13663&amp;PID=46667&amp;title=event-being-drawn-in-beforedrawthemeobject#46667</guid>
  </item> 
  <item>
   <title><![CDATA[Event being drawn in BeforeDrawThemeObject : Private Sub CalendarControl_BeforeDrawThemeObject(ByVal...]]></title>
   <link>http://forum.codejock.com/forum_posts.asp?TID=13663&amp;PID=46666&amp;title=event-being-drawn-in-beforedrawthemeobject#46666</link>
   <description>
    <![CDATA[<strong>Author:</strong> <a href="http://forum.codejock.com/member_profile.asp?PF=4721">mdoubson</a><br /><strong>Subject:</strong> 13663<br /><strong>Posted:</strong> 13 March 2009 at 1:11pm<br /><br /><DIV>Private Sub CalendarControl_BeforeDrawThemeObject(ByVal eObjType As XtremeCalendarControl.CalendarBeforeDrawThemeObject, ByVal Params As Variant)<BR>&nbsp;&nbsp;&nbsp; Dim pTheme2007 As CalendarThemeOffice2007<BR>&nbsp;&nbsp;&nbsp; Set pTheme2007 = CalendarControl.Theme<BR>&nbsp;&nbsp;&nbsp;&nbsp;<BR>&nbsp;&nbsp;&nbsp;&nbsp;<BR>&nbsp;&nbsp;&nbsp; If eObjType = xtpCalendarBeforeDraw_DayViewDay Then<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Debug.Print "BitmapID=" &amp; pTheme2007.DayView.Day.Header.BackgroundNormal.BitmapID<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; pTheme2007.DayView.Day.Header.BackgroundNormal.BitmapID = 0<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; <BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 'pTheme2007.DayView.Day.Group.SingleDayEvent.Normal.Body.Font.Strikethrough = True<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; pTheme2007.DayView.Day.Group.SingleDayEvent.Normal.Subject.Font.Strikethrough = True<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; <BR>&nbsp;&nbsp;&nbsp; End If<BR>......... </DIV><DIV>&nbsp;see snapshot <a href="https://forum.codejock.com/uploads/temp/20090313_131214_ScreenShot3.jpg" target="_blank">https://forum.codejock.com/uploads/temp/20090313_131214_ScreenShot3.jpg</A></DIV><DIV>&nbsp;</DIV><DIV>&nbsp;</DIV>]]>
   </description>
   <pubDate>Fri, 13 Mar 2009 13:11:39 +0000</pubDate>
   <guid isPermaLink="true">http://forum.codejock.com/forum_posts.asp?TID=13663&amp;PID=46666&amp;title=event-being-drawn-in-beforedrawthemeobject#46666</guid>
  </item> 
  <item>
   <title><![CDATA[Event being drawn in BeforeDrawThemeObject : I&amp;#039;m sorry but you might as...]]></title>
   <link>http://forum.codejock.com/forum_posts.asp?TID=13663&amp;PID=46661&amp;title=event-being-drawn-in-beforedrawthemeobject#46661</link>
   <description>
    <![CDATA[<strong>Author:</strong> <a href="http://forum.codejock.com/member_profile.asp?PF=3351">wakerunner</a><br /><strong>Subject:</strong> 13663<br /><strong>Posted:</strong> 13 March 2009 at 12:02pm<br /><br />I'm sorry but you might as well be speaking in Chinese, none of that means anything to me and it doesn't work in VB.<DIV>&nbsp;</DIV><DIV>Is there a support tech that knows VB?</DIV>]]>
   </description>
   <pubDate>Fri, 13 Mar 2009 12:02:11 +0000</pubDate>
   <guid isPermaLink="true">http://forum.codejock.com/forum_posts.asp?TID=13663&amp;PID=46661&amp;title=event-being-drawn-in-beforedrawthemeobject#46661</guid>
  </item> 
  <item>
   <title><![CDATA[Event being drawn in BeforeDrawThemeObject : in C++ OnBeforeDrawThemeObject(XTP_NOTIFY_CODE...]]></title>
   <link>http://forum.codejock.com/forum_posts.asp?TID=13663&amp;PID=46645&amp;title=event-being-drawn-in-beforedrawthemeobject#46645</link>
   <description>
    <![CDATA[<strong>Author:</strong> <a href="http://forum.codejock.com/member_profile.asp?PF=4721">mdoubson</a><br /><strong>Subject:</strong> 13663<br /><strong>Posted:</strong> 13 March 2009 at 11:03am<br /><br />in C++ <FONT size=2>OnBeforeDrawThemeObject(XTP_NOTIFY_CODE Event, WPARAM wParam , LPARAM lParam)<DIV></DIV><FONT size=2><P>Event&nbsp;can be&nbsp;XTP_NC_CALENDAR_BEFORE_DRAW_THEMEOBJECT</P><DIV>wParam&nbsp;can be&nbsp;<FONT size=2>xtpCalendarBeforeDraw_DayViewEvent</DIV><DIV></DIV>lParam can be <FONT size=2>CXTPCalendarDayViewEvent* pViewEvent = (CXTPCalendarDayViewEvent*)lParam;<DIV></DIV>from here you can get event as <FONT size=2>pViewEvent-&gt;GetEvent()<DIV></DIV>now you can get event properties e.g. <FONT size=2>GetSubject() and so on. <DIV></DIV><DIV>In ActiveX code there are enum:</DIV><DIV>&nbsp;typedef&nbsp;&nbsp;&#091; uuid(ECEC1B12-DD2C-47ab-8F12-9A813A074FAA), helpcontext(4493) &#093;<BR>&nbsp;enum<BR>&nbsp;{<BR>&nbsp;&nbsp;&#091;helpcontext(4493)&#093; xtpCalendarBeforeDraw_DayViewTimeScale&nbsp;&nbsp;&nbsp;= 0x00000001, // Params - (long) nTimeScale = {1 - main, 2 - additional}<BR>&nbsp;&nbsp;&#091;helpcontext(4493)&#093; xtpCalendarBeforeDraw_DayViewTimeScaleCaption&nbsp;= 0x00000002, // Params - (long) nTimeScale = {1 - main, 2 - additional};<BR>&nbsp;&nbsp;&#091;helpcontext(4493)&#093; xtpCalendarBeforeDraw_DayViewTimeScaleCell&nbsp;&nbsp;= 0x00000004, // Params - (Dispatch) CalendarThemeDayViewTimeScaleCellParams*<BR>&nbsp;&nbsp;&#091;helpcontext(4493)&#093; xtpCalendarBeforeDraw_DayViewDay&nbsp;&nbsp;&nbsp;&nbsp;= 0x00000010, // Params - (Dispatch) CalendarViewDay*;<BR>&nbsp;&nbsp;&#091;helpcontext(4493)&#093; xtpCalendarBeforeDraw_DayViewDayGroup&nbsp;&nbsp;&nbsp;= 0x00000020, // Params - (Dispatch) CalendarViewGroup*;<BR>&nbsp;&nbsp;&#091;helpcontext(4493)&#093; xtpCalendarBeforeDraw_DayViewCell&nbsp;&nbsp;&nbsp;&nbsp;= 0x00000040, // Params - (Dispatch) CalendarThemeDayViewCellParams*;<BR>&nbsp;&nbsp;&#091;helpcontext(4493)&#093; xtpCalendarBeforeDraw_DayViewEvent&nbsp;&nbsp;&nbsp;&nbsp;= 0x00000080, // Params - (Dispatch) CalendarViewEvent*;</DIV><DIV>&nbsp;&nbsp;&#091;helpcontext(4493)&#093; xtpCalendarBeforeDraw_MonthViewDay&nbsp;&nbsp;&nbsp;&nbsp;= 0x00001000, // Params - (Dispatch) CalendarViewDay*<BR>&nbsp;&nbsp;&#091;helpcontext(4493)&#093; xtpCalendarBeforeDraw_MonthViewEvent&nbsp;&nbsp;&nbsp;= 0x00002000, // Params - (Dispatch) CalendarViewEvent*<BR>&nbsp;&nbsp;&#091;helpcontext(4493)&#093; xtpCalendarBeforeDraw_MonthViewWeekDayHeader&nbsp;= 0x00004000, // Params - (long) WeekDay = {1-Sun, 2-Mon, ...},&nbsp;-1 for common part;<BR>&nbsp;&nbsp;&#091;helpcontext(4493)&#093; xtpCalendarBeforeDraw_MonthViewWeekHeader&nbsp;&nbsp;= 0x00008000, // Params - (long) WeekIndex={0...N}, -1 for common part;</DIV><DIV>&nbsp;&nbsp;&#091;helpcontext(4493)&#093; xtpCalendarBeforeDraw_WeekViewDay&nbsp;&nbsp;&nbsp;&nbsp;= 0x00100000, // Params - (Dispatch) CalendarViewDay*&nbsp;<BR>&nbsp;&nbsp;&#091;helpcontext(4493)&#093; xtpCalendarBeforeDraw_WeekViewEvent&nbsp;&nbsp;&nbsp;&nbsp;= 0x00200000, // Params - (Dispatch) CalendarViewEvent*</DIV><DIV>&nbsp;} CalendarBeforeDrawThemeObject;<BR></DIV><DIV>also &nbsp;typedef&nbsp;&nbsp;&nbsp;&#091; uuid(C9D2A6AD-CFFA-49ec-9DE4-24738B9F1E72), helpcontext(4509) &#093;<BR>&nbsp;enum<BR>&nbsp;{<BR>&nbsp;&nbsp;&#091;helpcontext(4509)&#093; xtpCalendarItemText_EventSubject&nbsp;&nbsp;&nbsp;= 0x00000001, <BR>&nbsp;&nbsp;&#091;helpcontext(4509)&#093; xtpCalendarItemText_EventLocation&nbsp;&nbsp;&nbsp;= 0x00000002,</DIV><DIV>&nbsp;&nbsp;&#091;helpcontext(4509)&#093; xtpCalendarItemText_DayViewDayHeader&nbsp;&nbsp;= 0x00000004,<BR>&nbsp;&nbsp;&#091;helpcontext(4509)&#093; xtpCalendarItemText_WeekViewDayHeader&nbsp;&nbsp;= 0x00000008,<BR>&nbsp;&nbsp;&#091;helpcontext(4509)&#093; xtpCalendarItemText_MonthViewDayHeader&nbsp;&nbsp;= 0x00000010,</DIV><DIV>&nbsp;&nbsp;&#091;helpcontext(4509)&#093; xtpCalendarItemText_MonthViewWeekDayHeader&nbsp;= 0x00000020,<BR>&nbsp;&nbsp;<BR>&nbsp;&nbsp;&#091;helpcontext(4509)&#093; xtpCalendarItemText_EventToolTipText&nbsp;&nbsp;= 0x00000040,<BR>&nbsp;<BR>&nbsp;&nbsp;&#091;helpcontext(4509)&#093; xtpCalendarItemText_EventStartTimeText&nbsp;&nbsp;= 0x00000100,<BR>&nbsp;&nbsp;&#091;helpcontext(4509)&#093; xtpCalendarItemText_EventEndTimeText&nbsp;&nbsp;= 0x00000200,</DIV><DIV>&nbsp;<BR>&nbsp;} XTPCalendarGetItemText;</DIV><DIV>&nbsp;</DIV><DIV>&nbsp;&nbsp;&nbsp;&#091;id(25), propget, helpcontext(4507)&#093; CalendarFlagsSet* AskItemTextFlags();<BR>&nbsp;&nbsp;&nbsp;&#091;id(26), propget, helpcontext(4522)&#093; CalendarFlagsSet* BeforeDrawThemeObjectFlags();</DIV><DIV>&nbsp;</DIV><DIV>and finally function void CCalendarControlCtrl::OnEvent_BeforeDrawThemeObject(XTP_NOTIFY_CODE Event, WPARAM dwParam1, LPARAM dwParam2)<BR>{<BR>&nbsp;ASSERT(XTP_NC_CALENDAR_BEFORE_DRAW_THEMEOBJECT == Event);<BR>&nbsp;<BR>&nbsp;if (XTP_NC_CALENDAR_BEFORE_DRAW_THEMEOBJECT != Event)<BR>&nbsp;{&nbsp;&nbsp; <BR>&nbsp;&nbsp;return;<BR>&nbsp;}<BR>&nbsp;&nbsp;<BR>&nbsp;int nObjType = (XTPCalendarBeforeDrawThemeObject)dwParam1;<BR>&nbsp;COleVariant varParams;<BR>&nbsp;varParams.vt = VT_EMPTY;</DIV><DIV>&nbsp;CCmdTarget* pObject = NULL;</DIV><DIV>&nbsp;switch (nObjType)<BR>&nbsp;{<BR>&nbsp;case xtpCalendarBeforeDraw_DayViewTimeScale:<BR>&nbsp;case xtpCalendarBeforeDraw_DayViewTimeScaleCaption:<BR>&nbsp;case xtpCalendarBeforeDraw_MonthViewWeekDayHeader:<BR>&nbsp;case xtpCalendarBeforeDraw_MonthViewWeekHeader:<BR>&nbsp;&nbsp;varParams = (long)dwParam2;<BR>&nbsp;&nbsp;break;<BR>&nbsp;case xtpCalendarBeforeDraw_DayViewTimeScaleCell:&nbsp;&nbsp;<BR>&nbsp;&nbsp;if (!m_pThemeDVTSCellParamsHolder)<BR>&nbsp;&nbsp;{<BR>&nbsp;&nbsp;&nbsp;m_pThemeDVTSCellParamsHolder = new CCalendarThemeDayViewTimeScaleCellParams_imp();<BR>&nbsp;&nbsp;&nbsp;if (!m_pThemeDVTSCellParamsHolder)<BR>&nbsp;&nbsp;&nbsp;&nbsp;return;<BR>&nbsp;&nbsp;}&nbsp;&nbsp;<BR>&nbsp;&nbsp;ASSERT(dwParam2);<BR>&nbsp;&nbsp;m_pThemeDVTSCellParamsHolder-&gt;SetDataRef((XTP_CALENDAR_THEME_DAYVIEWTIMESCALECELL_PARAMS*)dwParam2);<BR>&nbsp;&nbsp;pObject = m_pThemeDVTSCellParamsHolder;<BR>&nbsp;&nbsp;<BR>&nbsp;&nbsp;break;</DIV><DIV>&nbsp;case xtpCalendarBeforeDraw_DayViewDay:&nbsp;&nbsp;// dwParam2 - &#091;in&#093; pDayViewDay;&nbsp;&nbsp;<BR>&nbsp;&nbsp;ASSERT(dwParam2);<BR>&nbsp;&nbsp;pObject = (CCmdTarget*)(CXTPCalendarDayViewDay*)dwParam2;&nbsp;&nbsp;&nbsp;<BR>&nbsp;&nbsp;break;<BR>&nbsp;<BR>&nbsp;case xtpCalendarBeforeDraw_DayViewDayGroup: // dwParam2 - &#091;in&#093; pDayViewGroup;<BR>&nbsp;&nbsp;ASSERT(dwParam2);<BR>&nbsp;&nbsp;pObject = (CCmdTarget*)(CXTPCalendarDayViewGroup*)dwParam2;<BR>&nbsp;&nbsp;break;</DIV><DIV>&nbsp;case xtpCalendarBeforeDraw_DayViewCell:&nbsp;&nbsp;// dwParam2 - &#091;in&#093; XTP_CALENDAR_THEME_DAYVIEWCELL_PARAMS *;<BR>&nbsp;&nbsp;if (!m_pThemeDVCellParamsHolder)<BR>&nbsp;&nbsp;{<BR>&nbsp;&nbsp;&nbsp;m_pThemeDVCellParamsHolder = new CCalendarThemeDayViewCellParams_imp();<BR>&nbsp;&nbsp;&nbsp;if (!m_pThemeDVCellParamsHolder)<BR>&nbsp;&nbsp;&nbsp;&nbsp;return;<BR>&nbsp;&nbsp;}&nbsp;&nbsp;<BR>&nbsp;&nbsp;ASSERT(dwParam2);<BR>&nbsp;&nbsp;m_pThemeDVCellParamsHolder-&gt;SetDataRef((XTP_CALENDAR_THEME_DAYVIEWCELL_PARAMS*)dwParam2);<BR>&nbsp;&nbsp;pObject = m_pThemeDVCellParamsHolder;<BR>&nbsp;&nbsp;break;</DIV><DIV>&nbsp;case xtpCalendarBeforeDraw_DayViewEvent:&nbsp;// dwParam2 - &#091;in&#093; pDayViewEvent;<BR>&nbsp;&nbsp;ASSERT(dwParam2);<BR>&nbsp;&nbsp;pObject = (CCmdTarget*)(CXTPCalendarDayViewEvent*)dwParam2;<BR>&nbsp;&nbsp;break;</DIV><DIV>&nbsp;//=======================================================================<BR>&nbsp;case xtpCalendarBeforeDraw_MonthViewDay:&nbsp;&nbsp;// dwParam2 - &#091;in&#093; pMonthViewDay;<BR>&nbsp;&nbsp;ASSERT(dwParam2);<BR>&nbsp;&nbsp;pObject = (CCmdTarget*)(CXTPCalendarMonthViewDay*)dwParam2;<BR>&nbsp;&nbsp;break;</DIV><DIV>&nbsp;case xtpCalendarBeforeDraw_MonthViewEvent:&nbsp;&nbsp;// dwParam2 - &#091;in&#093; pMonthViewEvent;<BR>&nbsp;&nbsp;ASSERT(dwParam2);<BR>&nbsp;&nbsp;pObject = (CCmdTarget*)(CXTPCalendarMonthViewEvent*)dwParam2;<BR>&nbsp;&nbsp;break;</DIV><DIV>&nbsp;//=======================================================================<BR>&nbsp;case xtpCalendarBeforeDraw_WeekViewDay:&nbsp;&nbsp;// dwParam2 - &#091;in&#093; pWeekViewDay;<BR>&nbsp;&nbsp;ASSERT(dwParam2);<BR>&nbsp;&nbsp;pObject = (CCmdTarget*)(CXTPCalendarWeekViewDay*)dwParam2;<BR>&nbsp;&nbsp;break;</DIV><DIV>&nbsp;case xtpCalendarBeforeDraw_WeekViewEvent:&nbsp;&nbsp;// dwParam2 - &#091;in&#093; pWeekViewEvent;<BR>&nbsp;&nbsp;ASSERT(dwParam2);<BR>&nbsp;&nbsp;pObject = (CCmdTarget*)(CXTPCalendarWeekViewEvent*)dwParam2;<BR>&nbsp;&nbsp;break;</DIV><DIV>&nbsp;default:<BR>&nbsp;&nbsp;ASSERT(FALSE);<BR>&nbsp;&nbsp;return;<BR>&nbsp;}</DIV><DIV>&nbsp;//------------------------------------------------<BR>&nbsp;if (pObject)<BR>&nbsp;{<BR>&nbsp;&nbsp;varParams.vt = VT_DISPATCH;<BR>&nbsp;&nbsp;varParams.pdispVal = pObject-&gt;GetIDispatch(TRUE);<BR>&nbsp;}</DIV><DIV>&nbsp;//================================================<BR>&nbsp;FireBeforeDrawThemeObject(nObjType, &amp;varParams);<BR>&nbsp;//================================================</DIV><DIV>&nbsp;if (m_pThemeDVTSCellParamsHolder)<BR>&nbsp;&nbsp;m_pThemeDVTSCellParamsHolder-&gt;SetDataRef(NULL);</DIV><DIV>&nbsp;if (m_pThemeDVCellParamsHolder)<BR>&nbsp;&nbsp;m_pThemeDVCellParamsHolder-&gt;SetDataRef(NULL);<BR>}<BR><BR>It should help you to analyze passed params<BR></DIV></FONT></FONT></FONT></FONT></FONT></FONT>]]>
   </description>
   <pubDate>Fri, 13 Mar 2009 11:03:24 +0000</pubDate>
   <guid isPermaLink="true">http://forum.codejock.com/forum_posts.asp?TID=13663&amp;PID=46645&amp;title=event-being-drawn-in-beforedrawthemeobject#46645</guid>
  </item> 
  <item>
   <title><![CDATA[Event being drawn in BeforeDrawThemeObject : This is the code from the sample...]]></title>
   <link>http://forum.codejock.com/forum_posts.asp?TID=13663&amp;PID=46642&amp;title=event-being-drawn-in-beforedrawthemeobject#46642</link>
   <description>
    <![CDATA[<strong>Author:</strong> <a href="http://forum.codejock.com/member_profile.asp?PF=3351">wakerunner</a><br /><strong>Subject:</strong> 13663<br /><strong>Posted:</strong> 13 March 2009 at 10:42am<br /><br />This is the code from the sample program, I have that. Unless I am missing something there is no place in that code that tells me the "topicID" of the event or any other refernece to the specific event, only references to details about the graphical characteristics of the object being drawn.<DIV>&nbsp;</DIV><DIV>Maybe I am trying to do something in the wrong place. What i am trying to do is have the Subject drawn with a strikeout font when a custom xml property of the event "completed" = true.</DIV>]]>
   </description>
   <pubDate>Fri, 13 Mar 2009 10:42:42 +0000</pubDate>
   <guid isPermaLink="true">http://forum.codejock.com/forum_posts.asp?TID=13663&amp;PID=46642&amp;title=event-being-drawn-in-beforedrawthemeobject#46642</guid>
  </item> 
 </channel>
</rss>