This is a migrated thread and some comments may be shown as answers.

How to set the appointment Selected style?

1 Answer 74 Views
Scheduler and Reminder
This is a migrated thread and some comments may be shown as answers.
Cooper
Top achievements
Rank 1
Cooper asked on 15 Aug 2014, 03:57 AM
Telerik Members: 

Is it possible to set the selected appointment border's style? 

Thank you 

1 Answer, 1 is accepted

Sort by
0
Stefan
Telerik team
answered on 15 Aug 2014, 07:24 AM
Hello Cooper,

Thank you for writing.

Here is how you can modify the scheduler border:
void radScheduler1_AppointmentFormatting(object sender, SchedulerAppointmentEventArgs e)
{
    if (e.AppointmentElement.Selected)
    {
        e.AppointmentElement.UseDefaultPaint = true;
        e.AppointmentElement.BorderColor = Color.Red;
        e.AppointmentElement.BorderBoxStyle = BorderBoxStyle.SingleBorder;
        e.AppointmentElement.BorderWidth = 3;
    }
    else
    {
        e.AppointmentElement.UseDefaultPaint = false;
        e.AppointmentElement.ResetValue(LightVisualElement.BorderColorProperty, ValueResetFlags.Local);
        e.AppointmentElement.ResetValue(LightVisualElement.BorderWidthProperty, ValueResetFlags.Local);
        e.AppointmentElement.ResetValue(LightVisualElement.BorderBoxStyleProperty, ValueResetFlags.Local);
    }
}

I hope this helps.

Regards,
Stefan
Telerik
 
Check out Telerik Analytics, the service which allows developers to discover app usage patterns, analyze user data, log exceptions, solve problems and profile application performance at run time. Watch the videos and start improving your app based on facts, not hunches.
 
Tags
Scheduler and Reminder
Asked by
Cooper
Top achievements
Rank 1
Answers by
Stefan
Telerik team
Share this question
or