Your Privacy Matters: We use our own and third-party cookies to improve your experience on our website. By continuing to use the website we understand that you accept their use. Cookie Policy
40
how to force display of expired appointments?
posted

I have a requirement to display scheduled appointments on a calendar, so I am trying to use the WebSchedule controls. However, when I load the data into the WebScheduleInfo object, any appointment that is already past due is not visible. This is a problem because we need to show this data. How do we get these appointments to display?

 Thanks

Jeff

Parents
No Data
Reply
  • 4960
    posted

    If you attach a WebDayView control to the WebScheduleInfo by setting the day view's WebScheduleInfo property to the WebScheduleInfo instance you have loaded with data, it will by default display one day's worth of appointments.  You can broaden this by setting the day view's VisibleDays property up to 14.

    On the other hand, if you attach a WebMonthView control to the WebScheduleInfo, then you will see the current month by default.  Depending on the date of the month, anything from a few days worth of old appointments to (on the 31st) a month or more of old appointments may be visible.

    You can set the ActiveDayUtc property on the WebScheduleInfo to determine what consistutes the "current" month or day of its attached views.

    So your choice of view control will determine how much is visible at any one time.  Users can also scroll the view control into the past, by clicking the right-facing navigation arrow button often located in the top left corner of the view control.  In this way, you should be able to get to the appointments that occured in the past.

    If you are loading your data from the database, rather than manually populating the Activities collection on the WebScheduleInfo, then you can control how many old appointments are fetched (at least, the date range from which they are fetched) by setting the FrameInterval.  The frame interval is negotiated by all of the controls attached to the WebScheduleInfo - day views of course only require a day's worth of appointments to be loaded while month views require over a month of appointments to be loaded.  The frame interval grows during this negotiation process to accommodate the maximum data needs of the attached view controls.  You hook into this negotiation by handling the FrameIntervalChanged event on the WebScheduleInfo control, where you can override whatever interval was arrived at with your own (for example, to force a full year of old appointments to be loaded).

    HTH,

Children
No Data