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

Remove or blank status

2 Answers 107 Views
Scheduler and Reminder
This is a migrated thread and some comments may be shown as answers.
Jeff
Top achievements
Rank 1
Jeff asked on 28 Jul 2014, 09:22 PM
I use the status to show whether or not a guest has been assigned to the appointment. If not, this is shown with a white status bar using a custom status. This works great. However, when the status changes, I want to remove the status bar but I can't figure out how. If I set the custom status to transparent, the bar turns gray and if I use a status that doesn't exist, the background is the same color but I still see the border for the status. 

This is the code. Status 7 works great. Status 6 produces the gray bar but when commented out I get the result seen in the attached image.
Me.RadScheduler1.Statuses.Add(New AppointmentStatusInfo(6, "Guests", Color.Transparent, Color.Transparent, AppointmentStatusFillType.Solid))
Me.RadScheduler1.Statuses.Add(New AppointmentStatusInfo(7, "NoGuests", Color.White, Color.White, AppointmentStatusFillType.Solid))


I want the status bar to go away and the text to move back to the left a little. How can I do this?



The top of the image shows an appointment before a guest is added and the bottom is with a guest. The lock icon just indicates that the max number of guests have been added and isn't related to this issue.

2 Answers, 1 is accepted

Sort by
0
Dimitar
Telerik team
answered on 31 Jul 2014, 10:57 AM
Hi Jeff,

Thank for writing.

You can use the AppointmentFormatting event and disable the additional border: 
void radScheduler1_AppointmentFormatting(object sender, SchedulerAppointmentEventArgs e)
{
    if (e.Appointment.StatusId == 6)
    {
        e.AppointmentElement.UseDefaultPaint = true;
    }
    else
    {
        e.AppointmentElement.UseDefaultPaint = false;
    }
  
}

I hope this helps. Should you have any other questions do not hesitate to ask.
 
Regards,
Dimitar
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.
 
0
Jeff
Top achievements
Rank 1
answered on 31 Jul 2014, 02:41 PM
This is exactly what I need. Thank you!
Tags
Scheduler and Reminder
Asked by
Jeff
Top achievements
Rank 1
Answers by
Dimitar
Telerik team
Jeff
Top achievements
Rank 1
Share this question
or