<?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 : Show new &#101;vent</title>
  <link>http://forum.codejock.com/</link>
  <description><![CDATA[This is an XML content feed of; Codejock Developer Community : Calendar : Show new &#101;vent]]></description>
  <copyright>Copyright (c) 2006-2013 Web Wiz Forums - All Rights Reserved.</copyright>
  <pubDate>Wed, 13 May 2026 11:13:26 +0000</pubDate>
  <lastBuildDate>Sun, 21 May 2006 03:13:46 +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=4225</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[Show new &#101;vent : Serge, This is very embarassing!!!! It...]]></title>
   <link>http://forum.codejock.com/forum_posts.asp?TID=4225&amp;PID=13066&amp;title=show-new-event#13066</link>
   <description>
    <![CDATA[<strong>Author:</strong> <a href="http://forum.codejock.com/member_profile.asp?PF=2015">IDBG</a><br /><strong>Subject:</strong> 4225<br /><strong>Posted:</strong> 21 May 2006 at 3:13am<br /><br /><P>Serge,</P><P>This is very embarassing!!!!</P><P>It works fine!!&nbsp; My issue was I had the wrong instance of the form</P><P><IMG src="http://forum.codejock.com/smileys/smiley9.gif" border="0"><IMG src="http://forum.codejock.com/smileys/smiley9.gif" border="0"><IMG src="http://forum.codejock.com/smileys/smiley9.gif" border="0"></P><P>It works absolutely great!!!</P><P>Thanks!<BR>Mir</P>]]>
   </description>
   <pubDate>Sun, 21 May 2006 03:13:46 +0000</pubDate>
   <guid isPermaLink="true">http://forum.codejock.com/forum_posts.asp?TID=4225&amp;PID=13066&amp;title=show-new-event#13066</guid>
  </item> 
  <item>
   <title><![CDATA[Show new &#101;vent : Hi Serge, Here&amp;#039;s the routine. Public...]]></title>
   <link>http://forum.codejock.com/forum_posts.asp?TID=4225&amp;PID=13035&amp;title=show-new-event#13035</link>
   <description>
    <![CDATA[<strong>Author:</strong> <a href="http://forum.codejock.com/member_profile.asp?PF=2015">IDBG</a><br /><strong>Subject:</strong> 4225<br /><strong>Posted:</strong> 19 May 2006 at 1:09am<br /><br /><P>Hi Serge,</P><P>Here's the routine.</P><P>Public RMan As New CalendarResourcesManager<BR>Dim pData As CalendarDataProvider<BR>Dim pSchedules As CalendarSchedules<BR>Dim pRCDesc As CalendarResourceDescription</P><P>If RMan.AddDataProvider("", 32) = False Then<BR>&nbsp;&nbsp;&nbsp; Exit Sub<BR>End If<BR>&nbsp;&nbsp;&nbsp; </P><P>Set pData = RMan.DataProvider(0)<BR>Set pSchedules = pData.Schedules<BR>Set Rscs = Me.CalendarControl.MultipleResources<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; <BR>Dim strName As String<BR>Dim i As Integer, j As Integer<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; <BR>j = pSchedules.Count<BR>While j &gt; 0<BR>&nbsp;&nbsp;&nbsp; pSchedules.RemoveSchedule (j)<BR>&nbsp;&nbsp;&nbsp;&nbsp;j = j - 1<BR>Wend</P><P>j = RMan.ResourcesCount<BR>While j &gt; 0<BR>&nbsp;&nbsp;&nbsp; RMan.RemoveResource (j - 1)<BR>&nbsp;&nbsp;&nbsp;&nbsp;j = j - 1<BR>Wend<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; <BR>pData.Save<BR>RMan.SaveCfg App.Path &amp; "\MCal.xtpCal"<BR>Set Rscs = Me.CalendarControl.MultipleResources<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; <BR>i = 0<BR>j = 0<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; <BR>'First process all users<BR>For i = 0 To 19<BR>&nbsp;&nbsp;&nbsp; If arCals(i) &lt;&gt; "" Then<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; strName = frmPaneCalendar.trvCalendar.Nodes(arCals(i)).Text<BR> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;pSchedules.A ddNewSchedule strName<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;pData.Save<BR> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;RMan.AddReso urce strName, True<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Set pRCDesc = RMan.Resource(j)<BR> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;pRCDesc.Reso urce.SetDataProvider pData, False<BR> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;pRCDesc.Reso urce.ScheduleIDs.Add pSchedules(j).ID<BR> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;pRCDesc.Gene rateName = True<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;j = j + 1<BR>&nbsp;&nbsp;&nbsp;&nbsp;End If<BR>Next<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<BR>i = 0<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<BR> RMan.ApplyToCalendar Me.CalendarControl<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<BR> Me.CalendarControl.DataProvider.RemoveAllEvents</P><P>&lt;Open Recordset from database&gt;</P><P>&lt;do while not rst.eof&gt;<BR>&nbsp;&nbsp;&nbsp; Set cEvent = Me.CalendarControl.DataProvider.CreateEventEx(rst!ApptID)<BR>&nbsp;&nbsp;&nbsp; &lt;set all event properties and recurring properties&gt;<BR>&nbsp;&nbsp;&nbsp; &lt;cevent.ScheduleID=x&gt; 'To show&nbsp;for appropriate user<BR>&nbsp;&nbsp;&nbsp; Me.CalendarControl.DataProvider.AddEvent cEvent<BR>&lt;loop&gt;</P><P>Me.CalendarControl.Populate()<BR></P><P>Hope this helps.&nbsp; Thanks a bunch for your help!<BR><BR>If you'd like me to email you the VB module, please send me an e-mail address, and I'll be happy to do so.</P><P>Thanks!!<BR>Mir<BR></P>]]>
   </description>
   <pubDate>Fri, 19 May 2006 01:09:59 +0000</pubDate>
   <guid isPermaLink="true">http://forum.codejock.com/forum_posts.asp?TID=4225&amp;PID=13035&amp;title=show-new-event#13035</guid>
  </item> 
  <item>
   <title><![CDATA[Show new &#101;vent : Hi,It would be nice if you send...]]></title>
   <link>http://forum.codejock.com/forum_posts.asp?TID=4225&amp;PID=13021&amp;title=show-new-event#13021</link>
   <description>
    <![CDATA[<strong>Author:</strong> <a href="http://forum.codejock.com/member_profile.asp?PF=862">sserge</a><br /><strong>Subject:</strong> 4225<br /><strong>Posted:</strong> 18 May 2006 at 2:48pm<br /><br />Hi,<br><br>It would be nice if you send a piece of code which initializes calendar resources in your application, catches database events, and adds a new single event. It would allow me to analyze your steps in more details.<br><br><div><div><span style="font-family: 'Tahoma'; font-size: 12px; color: rgb(0, 0, 0); : transparent;">CalendarResourcesManager.AddDataProvider("", 0)</span><br></div></div>How do you manage a date provider?<br><br>Some more notes about data providers. <br>For resources you have to call one of following methods:<br><div><span style="font-family: 'Courier New'; font-size: 12px; color: rgb(0, 0, 0); : transparent;">    CalendarResource.SetDataProvider(DataProvider)</span></div><div><span style="font-family: 'Courier New'; font-size: 12px; color: rgb(0, 0, 0); : transparent;">    CalendarResource.SetDataProvider2(ConnectionString)</span></div><br>Normally, 1 data provider object is enough, and for a first resource you call SetDataProvider2 to create it and for others call like:<div><span style="font-family: 'Courier New'; font-size: 12px; color: rgb(0, 0, 0); : transparent;">objRCxxx.SetDataProvider(objRC0.DataProvider)<br></span></div><br>Also you can use CalendarResourcesManager like:<br><div><span style="font-family: 'Tahoma'; font-size: 12px; color: rgb(0, 0, 0); : transparent;">    CalendarResourcesManager.AddDataProvider("", xtpCalendarDPF_CloseOnDestroy)</span></div><div><span style="font-family: 'Courier New'; font-size: 12px; color: rgb(0, 0, 0); : transparent;"> </span></div><div><span style="font-family: 'Courier New'; font-size: 12px; color: rgb(0, 0, 0); : transparent;">  objRCxxx.SetDataProvider(</span><span style="font-family: 'Tahoma'; font-size: 12px; color: rgb(0, 0, 0); : transparent;">CalendarResourcesManager.</span><span style="font-family: 'Courier New'; font-size: 12px; color: rgb(0, 0, 0); : transparent;">DataProvider(0)</span><span style="font-family: 'Courier New'; font-size: 12px; color: rgb(0, 0, 0); : transparent;">)</span></div><br>CalendarControl.DataProvider property works like:&nbsp; CalendarControl.MultipleResources(0).DataProvider<br><br>Ensure that you have only one data provider for all resources.<br><br>--<br>WBR,<br>Serge<br>]]>
   </description>
   <pubDate>Thu, 18 May 2006 14:48:08 +0000</pubDate>
   <guid isPermaLink="true">http://forum.codejock.com/forum_posts.asp?TID=4225&amp;PID=13021&amp;title=show-new-event#13021</guid>
  </item> 
  <item>
   <title><![CDATA[Show new &#101;vent : Hi! Thanks for the response! I...]]></title>
   <link>http://forum.codejock.com/forum_posts.asp?TID=4225&amp;PID=12980&amp;title=show-new-event#12980</link>
   <description>
    <![CDATA[<strong>Author:</strong> <a href="http://forum.codejock.com/member_profile.asp?PF=2015">IDBG</a><br /><strong>Subject:</strong> 4225<br /><strong>Posted:</strong> 17 May 2006 at 1:49pm<br /><br /><P>Hi!&nbsp; Thanks for the response!</P><P>I know Method 1 isn't for this purpose, but I was trying that to see if maybe it'll work that way.</P><P>My app loads the Calendar in the following way:</P><P>- Load list of users<BR>- Load list of resources<BR>- User checks off users and resources he/she wants to see<BR>- Open recordset from db<BR>- Populate calendar</P><P>All this works perfectly.</P><P>This screen is still open when the user click "New Appointment"</P><P>On the "New Appointment" screen I save the new entry in the db<BR>- Create new CalendarEvent<BR>- Append this to the currently loaded calendar with<BR>&nbsp;&nbsp;&nbsp; CalendarControl.DataProvider.AddEvent CEvent<BR>&nbsp;&nbsp;&nbsp; CalendarControl.Populate()</P><P>Nothing happens.&nbsp; I've debugged and scheduleID's match, start and end times are accuarate and all other information is accurate. </P><P>Is there an issue if the calendar is "manually" populated first and if you are trying to add a new event manually again?</P><P>I've gone through the entire demo project line-by-line and I think I understand it well.&nbsp; I'm probably missing some small step somewhere..or at least I hope it's small <IMG src="http://forum.codejock.com/smileys/smiley1.gif" border="0">.</P><P><A href="https://forum.codejock.com/uploads/IDBG/2006-05-17_134906_ScrShot1.zip" target="_blank">2006-05-17_134906_ScrShot1.zip</A></P><P>Thanks again!</P><P>Mir</P>]]>
   </description>
   <pubDate>Wed, 17 May 2006 13:49:28 +0000</pubDate>
   <guid isPermaLink="true">http://forum.codejock.com/forum_posts.asp?TID=4225&amp;PID=12980&amp;title=show-new-event#12980</guid>
  </item> 
  <item>
   <title><![CDATA[Show new &#101;vent : Hi,Method 1 is not a method for...]]></title>
   <link>http://forum.codejock.com/forum_posts.asp?TID=4225&amp;PID=12977&amp;title=show-new-event#12977</link>
   <description>
    <![CDATA[<strong>Author:</strong> <a href="http://forum.codejock.com/member_profile.asp?PF=862">sserge</a><br /><strong>Subject:</strong> 4225<br /><strong>Posted:</strong> 17 May 2006 at 1:09pm<br /><br />Hi,<br><br>Method 1 is not a method for adding an event.<br>GetAllEventsRaw() is used to export all events or some similar purposes.<br><br>The correct order of action would be:<br>1) Open data provider(s)<br>2) Configure resources/schedules (if you need them)<br>3) Add events to data provider(s). You can use following methods:<br><div>&nbsp;&nbsp;<span style="font-family: 'Courier New'; font-size: 15px; color: rgb(0, 0, 0); : transparent;">CalendarControl.DataProvider.AddEvent</span></div><div>&nbsp;&nbsp;<span style="font-family: 'Courier New'; font-size: 15px; color: rgb(0, 0, 0); : transparent;">CalendarResource.DataProvider.AddEvent</span></div>4) When finished adding events, call CalendarControl.Populate()<br><br>When you add a single events, verify that some important properties are set correctly: StartTime, EndTime, ScheduleID, recurrence options if applicable.<br><br>I'd also suggest you to look deeper at our sample applications. See VB CalendarSample for following topics:<br>&nbsp;* Simple DataProviders.<br>&nbsp;&nbsp;&nbsp; Open/close a data provider; connection strings for different data provider types: memory, XML/binary, DataBase, MAPI.<br>&nbsp;* Resources/schedules.<br>&nbsp;&nbsp;&nbsp; Simple usage; extended - using resource manager (see corresponding menu items in the sample)<br>&nbsp;* Using "custom" data provider to work with custom DB. <br>&nbsp;&nbsp; See SQL Server example.<br><br>Also this forum contain a lot of information on those subjects.<br><br>--<br>WBR,<br>Serge<br>]]>
   </description>
   <pubDate>Wed, 17 May 2006 13:09:14 +0000</pubDate>
   <guid isPermaLink="true">http://forum.codejock.com/forum_posts.asp?TID=4225&amp;PID=12977&amp;title=show-new-event#12977</guid>
  </item> 
  <item>
   <title><![CDATA[Show new &#101;vent : Hi! We&amp;#039;re in the process...]]></title>
   <link>http://forum.codejock.com/forum_posts.asp?TID=4225&amp;PID=12956&amp;title=show-new-event#12956</link>
   <description>
    <![CDATA[<strong>Author:</strong> <a href="http://forum.codejock.com/member_profile.asp?PF=2015">IDBG</a><br /><strong>Subject:</strong> 4225<br /><strong>Posted:</strong> 16 May 2006 at 1:11pm<br /><br /><P>Hi!&nbsp; We're in the process of evaluating your software for our company.&nbsp; Everything works great, except for one issue.</P><P>When we tried setting the Calendar Control to an SQL database, we had a serious performance issue, so we are now manually creating all events.&nbsp; The&nbsp;code is pretty simple (VB6) ...</P><P>&lt;Setup calendar/resources/schedules&gt;<BR>&lt;open recordset&gt;<BR>&lt;Loop&gt;<BR>&nbsp;  &lt;calendarcontrol.dataprovider.CreateEventEx(rst("ID"))&gt ;<BR>&nbsp; &lt;set recurring properties&gt;<BR>&lt;end loop&gt;<BR>&lt;CalendarControl.Populate()&gt;</P><P>The issue I have is as follows:<BR>- When I create a new event and try to add it the current view, it won't show up.&nbsp; I've tried the following two methods:</P><P>Method 1: <BR>&lt;create new event in database table&gt;<BR>&lt;CalendarControl.GetAllEventsRaw()&gt;<BR>&lt;Append new event to this collection&gt;<BR>&lt;CalendarControl.Populate()&gt;</P><P>Method 2:<BR>&lt;Create new event in database table&gt;<BR> &lt;CalendarControl.DataProvider.CreateNewEventEx(rst("ID")) &gt;<BR>&lt;CalendarControl.DataProvider.AddEvent&gt;<BR>&lt;CalendarControl.Populate()&gt;</P><P>In both cases, the new event won't show up until I do the following</P><P>&lt;CalendarControl.dataprovider.RemoveAllEvents&gt;<BR>&lt;Remove all resources&gt;<BR>&lt;Remove all schedules&gt;<BR>&lt;Rebuild entire calendar from database table&gt;</P><P>Please help!&nbsp; I'm probably missing something.&nbsp; One quick note that might help...I couldn't get the calendar to show any events until I added the following:</P><P>If CalendarResourcesManager.AddDataProvider("", 0) = False Then<BR>&nbsp;&nbsp;&nbsp; Exit Sub<BR>End If</P><P>Could this be the problem?</P><P>Please help! We are <IMG src="http://forum.codejock.com/smileys/smiley11.gif" border="0">&nbsp;in the water until we resolve this issue!</P><P>Thanks!!!<BR>Mir</P><P>&nbsp;</P><P>&nbsp;</P>]]>
   </description>
   <pubDate>Tue, 16 May 2006 13:11:02 +0000</pubDate>
   <guid isPermaLink="true">http://forum.codejock.com/forum_posts.asp?TID=4225&amp;PID=12956&amp;title=show-new-event#12956</guid>
  </item> 
 </channel>
</rss>