Custom Appointments Dialog & Occurences

24 posts, 4 answers
  1. Matthew Green
    Matthew Green avatar
    27 posts
    Member since:
    Aug 2009

    Posted 24 Aug 2009 Link to this post

    Good afternoon,

    For the appointments i have a custom 'appointment' class that does not implement Telerik.WinControls.UI.Appointment. Binding is all fine to the scheduler, as well as adding, editing and moving of appointments via a custom Appointment Editor using IEditAppointmentDialog. I have added the Occurrence Dialog to load from the custom dialog however i am uncertain how to create recurrences. The information is passing fine between dialogs such that Telerik.WinControls.UI.RecurrenceRule is being updated on the custom appointment. The Rule isn't saving or loading (yet), but another thread has pointed out how to accomplish that part. So just testing from the edit dialog level at the moment.

    So the questions would be... 

    Main Questions
    1. How does the Scheduler defer that the item needs to be a recurrence and therefore show the items?
    2. If it builds off this field how does one tell it how to create the occurrences, otherwise how does one create them to be bindable to the control as well?

    Minor Goals
    1. Hide the context menu member (Right click on the radscheduler) "New Recurrening Appointment"
    2. Rename the context menu member "New Appointment" to something else

    Any more questions let me know.

    Best Regards

    Matthew Green
  2. Matthew Green
    Matthew Green avatar
    27 posts
    Member since:
    Aug 2009

    Posted 25 Aug 2009 Link to this post

    Ok, to make this task slightly more simple i have extended the appointment object and override a few properties to simulate the previous custom entity. Databinding is removed from the control and "appointments" are now being added via:-

            private ScheduleClinicEntity AddClinic(Entities.Clinic clinic) 
            { 
                var item = new ScheduleClinicEntity(clinic); 
     
                //Property handler to know when a field changes on a clinic 
                item.PropertyChanged += new PropertyChangedEventHandler(SchedulerItem_PropertyChanged); 
     
                //add item to the scheduler 
                RadScheduler.Appointments.Add(item); 
                 
                return item; 
            } 

    Occurrences appear now by overiding a method in the custom class as below:
            public override Telerik.WinControls.UI.IEvent CreateOccurrence(DateTime start) 
            { 
                var clinicClone = ClinicEntity.Clone(); 
     
                var newOccurence = new ScheduleClinicEntity(clinicClone); 
     
                return newOccurence; 
            } 

    To maintain the start and end dates of the clinic the entity is cloned as above, and so adjustments can be made to individual clinic dates, and logic.

    However the formating on the rad scheduler shows the items like new, and not as reacurrences. The item which created the reacurrences shows the symbol for the reacurences however the children do not. 

    Am i right in guessing that the property: Telerik.WinControls.UI.IEvent MasterEvent signifies whether they are a child or not to the scheduler? Then all i need to do is set this in the custom constructer ?

    Best Regards,

    Matthew Green
  3. Matthew Green
    Matthew Green avatar
    27 posts
    Member since:
    Aug 2009

    Posted 25 Aug 2009 Link to this post

            public ScheduleClinicEntity(Entities.Clinic clinic):base() 
            { 
                ClinicEntity = clinic; 
            } 
            public ScheduleClinicEntity(Entities.Clinic clinic, ScheduleClinicEntity master): this(clinic) 
            { 
                _masterEvent = master; 
            } 
            #region IEvent Members 
     
            /// <summary> 
            /// ... for repeated occurrences  
            /// </summary> 
            /// <param name="start"></param> 
            /// <returns></returns> 
            public override Telerik.WinControls.UI.IEvent CreateOccurrence(DateTime start) 
            { 
                var clone = ClinicEntity.Clone(); 
     
                var newOccurence = new ScheduleClinicEntity(clone, this); 
     
                newOccurence.Start = start; 
     
                return newOccurence; 
            } 
     
     
            private Telerik.WinControls.UI.IEvent _masterEvent; 
            public new Telerik.WinControls.UI.IEvent MasterEvent 
            { 
                get 
                { 
                    if (object.Equals(_masterEvent, null)) 
                        return null
                    else 
                        return _masterEvent; 
                } 
            } 

    Ok, this seems to have worked... Will this cause any side affects?  have i done this right ?

    Some more minor question still are outstanding if anyone is able to help ?

    1. Hide the context menu member (Right click on the radscheduler) - remove "New Recurrening Appointment"
    2. Rename the context menu member "New Appointment" to something else

    Thanks,

    Matthew Green
  4. Answer
    Jordan
    Admin
    Jordan avatar
    547 posts

    Posted 25 Aug 2009 Link to this post

    Hello Matthew Green,

    I was just about to point this forum thread to you, where I explain how RadScheduler creates occurrences using the CreateOccurrence method:
    http://www.telerik.com/community/forums/winforms/scheduler/recurrence-items.aspx
    It seems that you have already discovered this. You should just make sure that you are copying / setting all  properties that you need when creating the occurrences.

    Regarding your other questions, here is some sample code:
     
     public BindingSampleForm() 
            { 
                InitializeComponent(); 
     
                this.radScheduler1.ContextMenuShowing += new EventHandler<SchedulerContextMenuShowingEventArgs>(radScheduler1_ContextMenuShowing); 
            } 
     
            void radScheduler1_ContextMenuShowing(object sender, SchedulerContextMenuShowingEventArgs e) 
            { 
                e.ContextMenu.Items[0].Text = "Create new appointment"
                e.ContextMenu.Items[1].Visibility = Telerik.WinControls.ElementVisibility.Collapsed; 
            } 

    Basically, you handle the ContextMenuShowing event of RadScheduler and access the menu from the ContextMenu property of the event arguments.

    Do not hesitate to write again if you have more questions.

    Kind regards,
    Jordan
    the Telerik team

    Instantly find answers to your questions on the new Telerik Support Portal.
    Check out the tips for optimizing your support resource searches.
  5. Matthew Green
    Matthew Green avatar
    27 posts
    Member since:
    Aug 2009

    Posted 25 Aug 2009 Link to this post

    Thanks Jordan

    I remember reading that suggestion but had completely forgot about it when I was using databinding and that method never fired until i changed from databinding to adding to the appointments collection (much easier).

    While im sure I had found it on here earlier what would be the easiest way for translating the Recurrence Rule to string format and back again?
    - Never mind i remembered how to create it (i think its correct):
            public static string CreateRecurrenceRule(Telerik.WinControls.UI.RecurrenceRule rule) 
            { 
                return Telerik.WinControls.UI.Scheduler.ICalendar.CalHelper.RecurrenceRuleToString(rule); 
            } 
     
            public static Telerik.WinControls.UI.RecurrenceRule CreateRecurrenceRule(string rule) 
            { 
                Telerik.WinControls.UI.RecurrenceRule rrule = null
                Telerik.WinControls.UI.Scheduler.ICalendar.CalHelper.TryParseRecurrenceRule(rule, out rrule); 
     
                return rrule; 
            } 

    I will likely raise some questions about excluding certain dates through the Appointment Class...
    ie removing appointments on bank holidays, or days when staff are unavailable... Would moving an appointment from the Recurrence Collection to the Exclusion Collection resolve this case?

    Thanks again,

    Matthew Green

  6. Jordan
    Admin
    Jordan avatar
    547 posts

    Posted 28 Aug 2009 Link to this post

    Hello Matthew Green,

    Indeed, this is the correct way to convert recurrence rules to / from strings.
    Here is a related forum thread:
    http://www.telerik.com/community/forums/winforms/scheduler/recurrencerule.aspx

    Yes, to remove an occurrence of a recurring appointment you create an exception that is not visible.
    Basically you need to do something like this:

    occurrence.Visible = false;
    masterEvent.Exceptions.Add(occurrence);

    I hope this helps. Do not hesitate to write again if you have more questions.

    Greetings,
    Jordan
    the Telerik team

    Instantly find answers to your questions on the new Telerik Support Portal.
    Watch a video on how to optimize your support resource searches and check out more tips on the blogs.
  7. Matthew Green
    Matthew Green avatar
    27 posts
    Member since:
    Aug 2009

    Posted 28 Aug 2009 Link to this post

    Thanks again.

    My recurrence items are now complete (saving, editing and loading), so its back to main functionality.

    Is it possible to add a context menu to the appointments themselves, opening them is performed by double clicking however I would like to right click on them to have "edit entry" or something along those lines as well as other entries which open up other associated forms for the appointment.

    I also need to hide (or remove) the checkbox (for hiding and showing weekends) on the SchedulerNavigator appearing on the weekend and month view as it has no use on our calender.

    Other than that its looking quite good.

    Best Regards,
    Matthew Green
  8. Answer
    Jordan
    Admin
    Jordan avatar
    547 posts

    Posted 01 Sep 2009 Link to this post

    Hi Matthew Green,

    I am happy to see that your project is going well.

    You can easily add / change items in the context menu using the ContextMenuShowing event of RadScheduler like in the code sample bellow:
    private RadMenuItem editMenuItem = null
     
            void radScheduler1_ContextMenuShowing(object sender, SchedulerContextMenuShowingEventArgs e) 
            { 
                e.ContextMenu.Items[0].Text = "Create new appointment"
                e.ContextMenu.Items[1].Visibility = Telerik.WinControls.ElementVisibility.Collapsed; 
     
                if (this.editMenuItem == null
                { 
                    this.editMenuItem = new RadMenuItem("Edit appointment"); 
                    this.editMenuItem.Click += delegate 
                    { 
                        AppointmentElement appointmentElement = e.Element as AppointmentElement; 
                        MessageBox.Show("Edit appointment:\n" + appointmentElement.Appointment); 
                    }; 
                    e.ContextMenu.Items.Add(this.editMenuItem); 
                } 
     
                this.editMenuItem.Visibility = (e.Element is AppointmentElement) ?  
                    ElementVisibility.Visible : ElementVisibility.Collapsed; 
            } 

    Note the check for the AppointmentElement type. It is needed because the element can be of other type if the context menu is shown for another part of the scheduler, for example the time ruler.

    You can hide the weekend checkbox in the scheduler navigator with code like this:
     void Form1_Load(object sender, EventArgs e) 
            { 
     
                this.radSchedulerNavigator1.ShowWeekendCheckBox.Visibility = ElementVisibility.Collapsed; 
                this.radSchedulerNavigator1.ShowWeekendCheckBox.PropertyChanged += new PropertyChangedEventHandler(ShowWeekendCheckBox_PropertyChanged); 
            } 
     
            void ShowWeekendCheckBox_PropertyChanged(object sender, PropertyChangedEventArgs e) 
            { 
                if (e.PropertyName == "Visibility"
                { 
                    this.radSchedulerNavigator1.ShowWeekendCheckBox.Visibility = ElementVisibility.Collapsed; 
                } 
            } 

    I hope this helps. Do not hesitate to write again if you have more questions.

    Sincerely yours,
    Jordan
    the Telerik team

    Instantly find answers to your questions on the new Telerik Support Portal.
    Watch a video on how to optimize your support resource searches and check out more tips on the blogs.
  9. Matthew Green
    Matthew Green avatar
    27 posts
    Member since:
    Aug 2009

    Posted 02 Sep 2009 Link to this post

    Good work Jordon,

    The context menu part will be very useful.

    Thanks, Matthew
  10. Matthew Green
    Matthew Green avatar
    27 posts
    Member since:
    Aug 2009

    Posted 03 Sep 2009 Link to this post

    Month view

    I have several items appearing during each day, but with 4 or 5 weeks showing the amount of items which can be shown are limited to 3 or 4 (depending on the dimensions). Some of these days may hold a few more, would it be possible to display a visual cue or add scroll bars for the cells which require them?

    I had a go at trying to get to the cells:
    void clinicScheduler_ActiveViewChanged(object sender, SchedulerViewChangedEventArgs e) 
            { 
                var appointmentGroups = e.NewView.Appointments.GroupBy(n => n.Start.DayOfYear); 
     
                if (e.NewView.ViewType == SchedulerViewType.Month) 
                { 
                    SchedulerMonthViewElement monthView = 
                        this.clinicScheduler.SchedulerElement.ViewElement as SchedulerMonthViewElement; 
     
                    var childrenCollection = monthView.Children[1].Children.OfType<MonthCellElement>(); 
     
                    foreach (MonthCellElement cell in childrenCollection) 
                    { 
                        //var text = new RadElement() { Text = "k" }; 
                        //monthCell.Header.TextAlignment = ContentAlignment.TopLeft; 
                        cell.Enabled = false
                        cell.Header.Text = "k";  
                    } 
                } 
            } 

    However the cell was never disabled and the header text didn't change for any views. Having a look at the items in childrenCollection they all have the same date of {01/01/1980 00:00:00}. If I change the code above to get the items of type appointmentElement that seems to fetch the correct dates. Could you point me in the correct direction.

    Best Regards,

    Matthew
  11. Boyko Markov
    Admin
    Boyko Markov avatar
    610 posts

    Posted 04 Sep 2009 Link to this post

    Hi Matthew Green,

    Thank you for contacting us.

    1. I have prepared sample code which iterates through the children collection of MonthViewAreaElement and adds MonthCellElement instances to a monthcells list and AppointmentElement instances to appointments list:
     
       SchedulerMonthViewElement monthViewElement = this.radScheduler.SchedulerElement.ViewElement as SchedulerMonthViewElement;
                MonthViewAreaElement month = monthViewElement.Children[1] as MonthViewAreaElement;

                List<MonthCellElement> monthCells = new List<MonthCellElement>();
                List<AppointmentElement> appointments = new List<AppointmentElement>();
              
                foreach (RadElement element in month.Children)
                {
                    if (element as MonthCellElement != null)
                    {
                        monthCells.Add((MonthCellElement)element);
                        continue;
                    }

                    if (element as AppointmentElement != null)
                    {
                        appointments.Add((AppointmentElement)element);
                    }
                }

    2. In the current implementation, there is no way to add a scrollbar in a month cell or show a button indication that there are more appointments to be shown. We will take steps to improve this behavior in the next versions of the control.

    I have tested the code with the latest version of RadScheduler. Please write me back if you need more information.

    Regards,
    Boyko Markov
    the Telerik team

    Instantly find answers to your questions on the new Telerik Support Portal.
    Watch a video on how to optimize your support resource searches and check out more tips on the blogs.
  12. Matthew Green
    Matthew Green avatar
    27 posts
    Member since:
    Aug 2009

    Posted 04 Sep 2009 Link to this post

    Thanks Boyko Markov

    I will give that a go on Monday. The plan is to format the cell header to have a count of appointments for now that are found in the day of the month. Possibly adding buttons to cycle through the ones which are not visible on the day.  

    Here is a small correction to a sample provided earlier for adding edit to the context menu. Within the delegate it would always remember the first item which was selected during the creation of the delegate (subtle bug). So every time it will now look outside its scope and get the correct value (however i dont remember it failing first time I tested it.
    private RadMenuItem editMenuItem = null;  
    private AppointmentElement selected = null
     
    void radScheduler1_ContextMenuShowing(object sender, SchedulerContextMenuShowingEventArgs e)  
            {  
                e.ContextMenu.Items[0].Text = "Create new appointment";  
                e.ContextMenu.Items[1].Visibility = Telerik.WinControls.ElementVisibility.Collapsed;  
      
                selected = e.Element is AppointmentElement? e.Element as AppointmentElement: null; 
                if (this.editMenuItem == null)  
                {  
                    this.editMenuItem = new RadMenuItem("Edit appointment");  
                    this.editMenuItem.Click += delegate  
                    {  
                        //Keeps remembering the first selected item so element needs moving out of this state  
                        //AppointmentElement appointmentElement = e.Element as AppointmentElement;  
                        AppointmentElement appointmentElement = selected;
                        MessageBox.Show("Edit appointment:\n" + appointmentElement.Appointment);  
                    };  
                    e.ContextMenu.Items.Add(this.editMenuItem);  
                }  
      
                this.editMenuItem.Visibility = (e.Element is AppointmentElement) ?   
                    ElementVisibility.Visible : ElementVisibility.Collapsed;  
            }  

    Best regards,

    Matthew
  13. Matthew Green
    Matthew Green avatar
    27 posts
    Member since:
    Aug 2009

    Posted 06 Sep 2009 Link to this post

    Sorry Boyko

    The following hasnt worked for me:
    SchedulerMonthViewElement monthViewElement = this.clinicScheduler.SchedulerElement.ViewElement as SchedulerMonthViewElement;  
                MonthViewAreaElement month = monthViewElement.Children[1] as MonthViewAreaElement;  
     
                List<MonthCellElement> monthCells = new List<MonthCellElement>();  
                List<AppointmentElement> appointments = new List<AppointmentElement>();  
     
                foreach (RadElement element in month.Children)  
                {  
                    if (element as MonthCellElement != null)  
                    {  
                        monthCells.Add((MonthCellElement)element);  
                        continue;  
                    }  
     
                    if (element as AppointmentElement != null)  
                    {  
                        appointments.Add((AppointmentElement)element);  
                    }  
                }  
     
                var monthmonthCells2 = month.Children.OfType<MonthCellElement>();  
                var appointments2 = month.Children.OfType<AppointmentElement>();  
     
                foreach (var cell in monthCells2)  
                {  
                    cell.BackColor = Color.DarkRed;  
                    cell.Header.BackColor = Color.DeepPink;  
                      
                } 

    For both yours and my collection of monthcells the cells are not representing the current view. Every element comes out as below (focus on the date in the 1980):
    -       (new System.Collections.Generic.Mscorlib_CollectionDebugView<Telerik.WinControls.UI.MonthCellElement>(monthCells)).Items[0] {Telerik.WinControls.UI.MonthCellElement}   Telerik.WinControls.UI.MonthCellElement  
    +       base    {Telerik.WinControls.UI.MonthCellElement}   Telerik.WinControls.UI.SchedulerCellElement {Telerik.WinControls.UI.MonthCellElement}  
    -       Header  {Telerik.WinControls.UI.SchedulerCellElement}   Telerik.WinControls.UI.SchedulerCellElement  
    +       base    {Telerik.WinControls.UI.SchedulerCellElement}   Telerik.WinControls.UI.SchedulerVisualElement {Telerik.WinControls.UI.SchedulerCellElement}  
    -       Date    {01/01/1980 00:00:00}   System.DateTime  
    +       Date    {01/01/1980 00:00:00}   System.DateTime  
            Day 1   int  
            DayOfWeek   Tuesday System.DayOfWeek  
            DayOfYear   1   int  
            Hour    0   int  
            Kind    Unspecified System.DateTimeKind  
            Millisecond 0   int  
            Minute  0   int  
            Month   1   int  
            Second  0   int  
            Ticks   624511296000000000  long  
    +       TimeOfDay   {00:00:00}  System.TimeSpan  
            Year    1980    int  
    +       Static members        
    +       Non-Public members        
            IsToday false   bool  
            Selected    false   bool  
    +       Static members        
    +       Non-Public members        
            HeaderHeight    25  int 

    The MonthViewArea element is showing the correct date and time:
     +  StartDate {24/08/2009 00:00:00} System.DateTime
     +  EndDate {20/09/2009 00:00:00} System.DateTime
    however the monthcellelements are not.

    This wouldnt be a problem with the evaulation copy of the DLLs which are the ones im currently using? (purchasing a licence this month somewhen). Let me know what you think as soon as possible.

    Thanks,
    Matthew
  14. Matthew Green
    Matthew Green avatar
    27 posts
    Member since:
    Aug 2009

    Posted 08 Sep 2009 Link to this post

    Sorry a correction to my debugging for the previous post:


    //c# 3.5 Required  
     
    var monthCells = month.Children.OfType<MonthCellElement>(); 
    var appointments = month.Children.OfType<AppointmentElement>(); 
     
     

    These two lines produce the correct cells as you say. However the properties associated with the cell do not seem to signify the current cell.

    -       cell    {Telerik.WinControls.UI.MonthCellElement}   Telerik.WinControls.UI.MonthCellElement 
    -       base    {Telerik.WinControls.UI.MonthCellElement}   Telerik.WinControls.UI.SchedulerCellElement {Telerik.WinControls.UI.MonthCellElement} 
    +       base    {Telerik.WinControls.UI.MonthCellElement}   Telerik.WinControls.UI.SchedulerVisualElement {Telerik.WinControls.UI.MonthCellElement} 
    +       Date    {01/09/2009 00:00:00}   System.DateTime 
            IsToday false   bool 
            Selected    false   bool 
    +       Static members       
    +       Non-Public members       
    -       Header  {Telerik.WinControls.UI.SchedulerCellElement}   Telerik.WinControls.UI.SchedulerCellElement 
    +       base    {Telerik.WinControls.UI.SchedulerCellElement}   Telerik.WinControls.UI.SchedulerVisualElement {Telerik.WinControls.UI.SchedulerCellElement} 
    +       Date    {01/01/1980 00:00:00}   System.DateTime 
            IsToday false   bool 
            Selected    false   bool 
    +       Static members       
    +       Non-Public members       
            HeaderHeight    25  int 

    The above is the first item from the list. The base date is 01/09/2009 however the Header Date is 01/01/1980. The child element and only child of the cell are as I said are returning an element which is on the 01/01/1980:

    -       [0] {Telerik.WinControls.UI.SchedulerCellElement}   object {Telerik.WinControls.UI.SchedulerCellElement} 
    +       base    {Telerik.WinControls.UI.SchedulerCellElement}   Telerik.WinControls.UI.SchedulerVisualElement {Telerik.WinControls.UI.SchedulerCellElement} 
    +       Date    {01/01/1980 00:00:00}   System.DateTime 
            IsToday false   bool 
            Selected    false   bool 
    +       Static members       
    +       Non-Public members   

    Could you point where to alter the cells back colour; add controls to either the cell and or the header;

    Best Regards,

    Matthew
  15. Boyko Markov
    Admin
    Boyko Markov avatar
    610 posts

    Posted 10 Sep 2009 Link to this post

    Hi Matthew Green,

    Thank you for writing.

    1. Could you please give me more information about the version of RadControls for Winforms which you currently use? I'm asking this because we have made many fixes in RadScheduler in Q2 2009 SP1.

    2. Could you please give me more information about why you want to host controls in the cells of RadScheduler? What would be the purpose of doing this and is there any other option?

    I'm looking forward to your reply.

    Kind regards,
    Boyko Markov
    the Telerik team

    Instantly find answers to your questions on the new Telerik Support Portal.
    Watch a video on how to optimize your support resource searches and check out more tips on the blogs.
  16. Matthew Green
    Matthew Green avatar
    27 posts
    Member since:
    Aug 2009

    Posted 10 Sep 2009 Link to this post

    Thanks; 

    RE: 1. Could you please give me more information about the version of RadControls for Winforms which you currently use? I'm asking this because we have made many fixes in RadScheduler in Q2 2009 SP1.
    • The version installed is: RadControls for WinForms Q2 2009 SP1
    • The version number is: 2009.2.9.729
    • Runtime version: v2.0.50727

     

    RE: 2. Could you please give me more information about why you want to host controls in the cells of RadScheduler? What would be the purpose of doing this and is there any other option?

    Currently I am using two seperate scheduler controls but the main one dealing with clinics is troubling:
    The main Scheduler is (defaulted) to the month view, which displays 4 weeks. The other scheduler im not trying to do anything funny with. The main view shows when clinics are open and where someone can book appointments.

    Current Problems
    :
    Month view doesnt have the capbability to show all clinics in the month view cell. If all the clinics can not be seen they certain days will probably miss appointments beeing added to them. This can be solved if the user were filtering properly however some may want to see the progress over several clincs.
     
    Possible solutions:
    [
        1. Add a button(s) which allows the user to cycle the view on each cell view where there are too many clinics to show
        --- Already knowing the collection on each cell this should be relitively easy 
        2. Add a scroll bar to the cell like other views 
        --- Its already been said this was tried by your team but they were looking for something a bit better
        3. Adding a label giving a count of the current clinics in a month cell
        --- While letting the user know they will need to goto a differnt view its still not that intuitive.
    ]

    Current toying ideas:
    [
        Add two (small) buttons to the header of each cell allowing quick navigation from the month view to either the week or day view. 
        Targets: focus on that particular cell. 
        Alternatives: Add a button to the context menu when right clicking 
        Value: subjective; possibly more intuitive
    ]

    In both cases it would likely be adding button(s) to the header of each month cell and docking right. Partly this is about curiosity (that might prove to be useful) and partly to do with current limitations of the month view.

    I Hope the above helps.


    Best Regards,
    Matthew Green
  17. Answer
    Boyko Markov
    Admin
    Boyko Markov avatar
    610 posts

    Posted 10 Sep 2009 Link to this post

    Hello Matthew Green,

    For your convenience, I have prepared a simple project using RadScheduler and its MonthView which you could find as an attachment.

    When there are too many appointments in the monthview which are not rendered because there is no available space, I add a small arrow button in the bottom right corner of the month cell. When the user presses the button the scheduler is automatically navigated to the DayView with startDate equal to the cell's date. This will allow you to see all appointments for a current day. This behavior is similar to the one in MS Outlook.

    We will do our best to enhance the UI of SchedulerMonthView for the next Q3 release. This would be of top priority for us.

    Please write me back if you need more help with this scenario.
     

    Kind regards,
    Boyko Markov
    the Telerik team

    Instantly find answers to your questions on the new Telerik Support Portal.
    Watch a video on how to optimize your support resource searches and check out more tips on the blogs.
  18. Matthew Green
    Matthew Green avatar
    27 posts
    Member since:
    Aug 2009

    Posted 10 Sep 2009 Link to this post

    That should work very nicely for now. The example shows some quite useful features as well that i might use elsewhere. Thankyou Boyko Markov.

    You wouldn't happen to know if the scheduler is going to implement any features like in the following (Microsoft + NHS collaboration)
    http://www.mscui.net/PatientJourneyDemonstrator/PrimaryCareAdmin.htm (Silverlight example; not all the controls are working and many are just for show) 

    Features
    • Expanding and shrinking the entire day view from 1 hour scale to and from 10/15/30 min scales
    • Hiding and expanding particular hours to and from a given scale

    Best Regards,

     

    Matthew Green

  19. Boyko Markov
    Admin
    Boyko Markov avatar
    610 posts

    Posted 11 Sep 2009 Link to this post

    Hi Matthew Green,

    I am happy that the sample project has been helpful to you. I have checked the SL example. There are some interesting features that we could implement in some of our future versions. Please, do not hesitate to contact us if you have more questions.

    Sincerely yours,
    Boyko Markov
    the Telerik team

    Instantly find answers to your questions on the new Telerik Support Portal.
    Watch a video on how to optimize your support resource searches and check out more tips on the blogs.
  20. Matthew Green
    Matthew Green avatar
    27 posts
    Member since:
    Aug 2009

    Posted 11 Sep 2009 Link to this post

    Hello again Boyko Markov

    Small problem with the sample. When the active view changes on the month view the additional button element is lost (ie scrolling with the mouse wheel or with the arrow keys). Resizing adds it back in. This happens even if the month view changed event is added and calls ShowViewChangeButton() 
    Short of changing the view size is there an easy fix ?

    Thanks, Matthew
  21. Boyko Markov
    Admin
    Boyko Markov avatar
    610 posts

    Posted 16 Sep 2009 Link to this post

    Hello Matthew Green,

    You could subscribe to the scheduler keyUp event and call ShowViewChangeButton(); method. This should fix the problem. I hope this helps.

    Sincerely yours,
    Boyko Markov
    the Telerik team

    Instantly find answers to your questions on the new Telerik Support Portal.
    Watch a video on how to optimize your support resource searches and check out more tips on the blogs.
  22. Matthew Green
    Matthew Green avatar
    27 posts
    Member since:
    Aug 2009

    Posted 16 Sep 2009 Link to this post

    Thanks Boyko Markov

    I really should have thought of that. The mouse scroll is the only one causing any problems now. I have attached an event to it, it fires but the extra content isnt added to the new cells as well as cells where it is appended lose it once the user scrolls back into the view that originally had it. going over any of the other events recreates the content. Do you have any thoughts here?

    Best Regards,
    Matthew
  23. Answer
    Boyko Markov
    Admin
    Boyko Markov avatar
    610 posts

    Posted 18 Sep 2009 Link to this post

    Hello Matthew Green,

    I think we can workaround this. I tested it locally and I think that this kind of solution will help you.

    1. Create a new Timer:

      System.Windows.Forms.Timer timer;

    2.  Subscribe to MouseWheel event of RadScheduler and start the timer:

           void scheduler_MouseWheel(object sender, MouseEventArgs e)
            {
                if (this.timer != null)
                {
                    timer.Tick -= new EventHandler(timer_Tick);
                }

                timer = new System.Windows.Forms.Timer();
                timer.Tick += new EventHandler(timer_Tick);
                timer.Start();
            }

    3. Call ShowViewChangeButton method in the Timer tick event handler and stop the timer:

            void timer_Tick(object sender, EventArgs e)
            {
                this.timer.Stop();
                this.ShowViewChangeButton();
            }

    I hope this helps. Do not hesitate to write back if you have further questions.

    Sincerely yours,
    Boyko Markov
    the Telerik team

    Instantly find answers to your questions on the new Telerik Support Portal.
    Watch a video on how to optimize your support resource searches and check out more tips on the blogs.
  24. Matthew Green
    Matthew Green avatar
    27 posts
    Member since:
    Aug 2009

    Posted 28 Sep 2009 Link to this post

    Sorry for the delay,
     
    That will do nicely. Thanks for you help on this.

    Best Regards,
    Matthew Green
Back to Top