Print Page | Close Window

DoRetrieveDayEvents is fired continuously

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=19841
Printed Date: 04 December 2024 at 9:07pm
Software Version: Web Wiz Forums 12.04 - http://www.webwizforums.com


Topic: DoRetrieveDayEvents is fired continuously
Posted By: gandg
Subject: DoRetrieveDayEvents is fired continuously
Date Posted: 06 June 2012 at 5:27am
PRODUCT DETAILS:

Product:  Xtreme Calendar
Version:  15.3.1
Platform:  MS Access
OS:     Windows XP
SP:     3
SDK:    

SUPPORT REQUEST:

Hello,
we are developing a solution with the Xtreme Calendar control but it seems that, somehow, the DoRetrieveDayEvents keeps firing endlessly.

The code we use in _Load event is:

===================================

Private Sub Form_Load()
   
  Set m_Connection = CurrentDb
  Set TheCalendarControl = Me.CalendarControl1.Object
  m_pHelper.SetCalendar TheCalendarControl

  SetCalendarOptions
  
  Set wndDatePicker = Me.DatePicker2.Object
  wndDatePicker.AttachToCalendar TheCalendarControl

  ''TheCalendarControl.SetDataProvider "Provider=custom;DSN=Custom_MSACCESS"
  TheCalendarControl.SetDataProvider "Provider=custom"
  If Not TheCalendarControl.DataProvider.Open Then
    TheCalendarControl.DataProvider.Create
  End If
  OpenDB

   Dim Today As Date
  Today = Date
  TheCalendarControl.ViewType = xtpCalendarDayView
  TheCalendarControl.DayView.ShowDays Date - 2, Date + 3
  TheCalendarControl.ViewType = xtpCalendarWorkWeekView
  
  TheCalendarControl.Populate
  TheCalendarControl.DayView.ScrollToWorkDayBegin

  
End Sub

Private Function SetCalendarOptions()
  
  TheCalendarControl.Options.EnableAddNewTooltip = False
  
  '' don''t allow in place editing of the events
  TheCalendarControl.Options.EnableInPlaceEditEventSubject_ByMouseClick = False
  TheCalendarControl.Options.EnableInPlaceEditEventSubject_AfterEventResize = False
  TheCalendarControl.Options.EnableInPlaceEditEventSubject_ByF2 = False
  TheCalendarControl.Options.EnableInPlaceEditEventSubject_ByTab = False
  TheCalendarControl.Options.EnableInPlaceCreateEvent = False
  
  '' set work days / time
  TheCalendarControl.Options.WorkDayStartTime = TimeValue("08:00")
  TheCalendarControl.Options.WorkDayEndTime = TimeValue("20:00")
  TheCalendarControl.Options.WorkWeekMask = xtpCalendarDayMo_Fr Or xtpCalendarDaySaturday

  '' greek labels at Caption Bar
  TheCalendarControl.CaptionButtonTitle 0, "У‡УЌУУБУЁ"
  TheCalendarControl.CaptionButtonTitle 1, "У…УЂУЄУЏУЌУœУЄУЁ"
  TheCalendarControl.CaptionButtonTitle 2, "УŒУžУ­УЁУВ"
  TheCalendarControl.CaptionButtonTitle 3, ""
  TheCalendarControl.CaptionButtonTitle 4, "У…УБУЃ.У…УЂУЄ."
  TheCalendarControl.CaptionButtonTitle 5, "УУЋУЇУБ.У…УЂУЄ."
  TheCalendarControl.CaptionButtonTitle 6, "У“УДУžУЋУЅУВ"
    
  '' what we will show at caption bar
  TheCalendarControl.ShowTimelineButton = False
  TheCalendarControl.ShowCaptionBar = True
  TheCalendarControl.ShowCaptionBarDateLabel = True
  TheCalendarControl.ShowCaptionBarScrollDateButtons = True
  TheCalendarControl.ShowCaptionBarSwitchViewButtons = True
    
  TheCalendarControl.SetLongDayHeaderFormat ("ddd, dd MMMM")
  TheCalendarControl.WeekView.DayHeaderFormatLong = "ddd, dd MMMM"

End Function

================================

But, when we load the form, it keeps firing the DoRetrieveEvents event. From a sample run, the 764th through the 780th calls are for the days:

764: DoRetrieveEvents 25/6/2013
765: DoRetrieveEvents 23/5/2011
766: DoRetrieveEvents 22/5/2011
767: DoRetrieveEvents 26/6/2013
768: DoRetrieveEvents 27/6/2013
769: DoRetrieveEvents 21/5/2011
770: DoRetrieveEvents 20/5/2011
771: DoRetrieveEvents 28/6/2013
772: DoRetrieveEvents 29/6/2013
773: DoRetrieveEvents 19/5/2011
774: DoRetrieveEvents 18/5/2011
775: DoRetrieveEvents 30/6/2013
776: DoRetrieveEvents 1/7/2013
777: DoRetrieveEvents 17/5/2011
778: DoRetrieveEvents 16/5/2011
779: DoRetrieveEvents 2/7/2013
780: DoRetrieveEvents 3/7/2013

and some more to help you find a pattern:
2009: DoRetrieveEvents 8/9/2009
2010: DoRetrieveEvents 7/9/2009
2011: DoRetrieveEvents 10/3/2015
2012: DoRetrieveEvents 11/3/2015
2013: DoRetrieveEvents 6/9/2009
2014: DoRetrieveEvents 5/9/2009
2015: DoRetrieveEvents 12/3/2015
2016: DoRetrieveEvents 13/3/2015
2017: DoRetrieveEvents 4/9/2009
2018: DoRetrieveEvents 3/9/2009
2019: DoRetrieveEvents 14/3/2015
2020: DoRetrieveEvents 15/3/2015

We let it run and it did 6840 calls up to the year 2021...

Is there something wrong we do with the initialization of the component?

Looking forward for your response,

Best Regards,
George Stathis



Replies:
Posted By: el austriaco
Date Posted: 02 March 2013 at 10:14am
Hi George,

I'm having the same problem. I went through the examples provided by CodeJock but I could not figure out anything I could have forgotten.

Did you solve the problem? Any hints for me?

Georg


Posted By: starzen
Date Posted: 08 July 2013 at 10:32am
this issue seems to be an ongoing bug that seems to be ignored. I posted a message on this a long time ago and i saw another post on it all pretty much unanswered
 
what seems to happen is that if you have a day or day range displayed that doesnt have any data returned it just keeps going like the energizer bunny.
 
 


Posted By: ilya
Date Posted: 11 July 2013 at 7:38am
Can you please attach a simple demo project illustrating the issue?


Posted By: Marco1
Date Posted: 11 July 2013 at 8:49am
Knowing only the C++ calendar control, but it would be similar I guess...

A few hundred DoRetrieveDayEvents are okay, cause the DatePickerCtrl - I think you are using one - needs to be populated. That way a few month forward and backward are always fetched.
But up the the year 2021 seems way too far...



-------------
Product: XTP 18.3.0 on VS 2017
Platform: VS 2017 / Windows 10 (64bit)



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