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

How to disable the delete event when the login user is not the administrator?

2 Answers 71 Views
Scheduler
This is a migrated thread and some comments may be shown as answers.
Vinix
Top achievements
Rank 1
Vinix asked on 02 Mar 2008, 11:25 AM

I need to implement a Scheduler which only the administrator users can insert, update and delete the event of the RadScheduler. Please tell me how to disable the delete event. Thank you very much.

2 Answers, 1 is accepted

Sort by
0
Accepted
Piyush Bhatt
Top achievements
Rank 2
answered on 02 Mar 2008, 09:22 PM

You can handle AppointmentCreated event and in that, check whether current user is Administrator or not (you may want to store this in session). And change following flag accordingly:

void RadScheduler1_AppointmentCreated(object sender, AppointmentCreatedEventArgs e)
{
    if (Session("IsAdministrator")  == true)
        e.Appointment.AllowDelete = true;
    else
        e.Appointment.AllowDelete = false;
}

I am not from Telerik, but I hope they may have the same solution.
-Piyush
0
Vinix
Top achievements
Rank 1
answered on 03 Mar 2008, 03:08 AM
Many Thanks for your replying.
It is very helpful.
Tags
Scheduler
Asked by
Vinix
Top achievements
Rank 1
Answers by
Piyush Bhatt
Top achievements
Rank 2
Vinix
Top achievements
Rank 1
Share this question
or