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

Allow Delete & Edit are not working

1 Answer 70 Views
Scheduler
This is a migrated thread and some comments may be shown as answers.
Mehmet
Top achievements
Rank 1
Mehmet asked on 24 Jun 2014, 09:15 AM
01.protected void RadScheduler1_AppointmentDataBound(object sender, SchedulerEventArgs e)
02.        {
03.              
04.            e.Appointment.ToolTip = e.Appointment.Subject + ": " + e.Appointment.Description;
05. 
06.            if (e.Appointment.Attributes["JobStatusID"] == COMMON.Enumerations.JobStatusEnum.BOOKING.ToString())
07.            {
08.                e.Appointment.AllowDelete = true;
09.            }
10.            else if (e.Appointment.Attributes["JobStatusID"] != COMMON.Enumerations.JobStatusEnum.COMPLETED.ToString() || e.Appointment.Attributes["JobStatusID"] != COMMON.Enumerations.JobStatusEnum.CANCELLEDBYADMINISTRATOR.ToString() || e.Appointment.Attributes["JobStatusID"] != COMMON.Enumerations.JobStatusEnum.CANCELLEDBYMOBILE.ToString() || e.Appointment.Attributes["JobStatusID"] != COMMON.Enumerations.JobStatusEnum.CLOSED.ToString())
11.            {
12.                string colorValue = COMMON.Enumerations.GetJobStatusColor((COMMON.Enumerations.JobStatusEnum)int.Parse(e.Appointment.Attributes["JobStatusID"]));
13.                e.Appointment.BackColor = Color.FromName(colorValue);
14.                e.Appointment.AllowDelete = false;
15.                e.Appointment.AllowEdit = false;
16.                //e.Appointment.Attributes.CssStyle.Add("rsAptDelete ", "display:none !important;");
17.            }
18.            else
19.            {
20.                string colorValue = COMMON.Enumerations.GetJobStatusColor((COMMON.Enumerations.JobStatusEnum)int.Parse(e.Appointment.Attributes["JobStatusID"]));
21.                e.Appointment.BackColor = Color.FromName(colorValue);
22.                e.Appointment.AllowDelete = false;
23.                e.Appointment.AllowEdit = true;
24.                //e.Appointment.Attributes.CssStyle.Add("rsAptDelete ", "display:none !important;");
25.            }
26.        }

Hi, the above is my code and Allow Delete & Allow Edit are not working certainly. Does anybody have an idea ?
thank you

1 Answer, 1 is accepted

Sort by
0
Boyan Dimitrov
Telerik team
answered on 26 Jun 2014, 03:50 PM
Hello,

I would like to clarify that the appointment AllowDelete and AllowEdit functionalities  work as expected in Q2 2014 (version 2014.2 618). AllowDelete will not show the delete icon in upper left corner of the appointment so user is not able to delete the appointment. When AllowEdit is enabled the advanced form will not open if user double clicks on an appointment.

Regards,
Boyan Dimitrov
Telerik
 

Check out the Telerik Platform - the only platform that combines a rich set of UI tools with powerful cloud services to develop web, hybrid and native mobile apps.

 
Tags
Scheduler
Asked by
Mehmet
Top achievements
Rank 1
Answers by
Boyan Dimitrov
Telerik team
Share this question
or