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

Rad Schedular Edit only this occurence problem

4 Answers 104 Views
Calendar
This is a migrated thread and some comments may be shown as answers.
Kalpna
Top achievements
Rank 1
Kalpna asked on 21 Sep 2013, 09:07 AM
Hello...
When we click on recurrence activity to edit it. It shows two radio buttons (Edit only this occurrence and edit the series). I want to use only "Edit the series". How can i remove the "Edit only this occurrence" button from the window. Or is there any way to remove both and the recurring activity is displayed in edit mode? Please help me, its urgent.
Thanks in advance.

4 Answers, 1 is accepted

Sort by
0
Shinu
Top achievements
Rank 2
answered on 23 Sep 2013, 10:00 AM
Hi Kalpna,

One suggestion is you can directly open the Edit Appointment window in Recurrence Mode (that is Edit the Series) without displaying the confirmation popup whether you need to edit the occurrence or series. Please check the sample code which works fine at my end.

ASPX:
<telerik:RadScheduler runat="server" ID="RadScheduler1" SelectedView="WeekView" DisplayDeleteConfirmation="false"
    DisplayRecurrenceActionDialogOnMove="false" OnClientRecurrenceActionDialogShowing="OnClientRecurrenceActionDialogShowing">
</telerik:RadScheduler>

JavaScript:
function OnClientRecurrenceActionDialogShowing(sender, args)
{
    var action = args.get_recurrenceAction();
    var appointment = args.get_appointment();
    if (action == Telerik.Web.UI.RecurrenceAction.Edit)
    {
        args.set_cancel(true);
        sender.showAdvancedEditForm(appointment);
    } else if (action == Telerik.Web.UI.RecurrenceAction.Delete)
    {
        args.set_cancel(true);
        sender.deleteAppointment(appointment, false)
    } else //If the action is resize the event is just canceled.
    {
        args.set_cancel(false);
    }
}

Thanks,
Shinu.
0
Kalpna
Top achievements
Rank 1
answered on 24 Sep 2013, 05:56 AM
Thank you so much. But this will providing a blank form because the scheduler does not get the id of appointment.
And on Edit the series it will get the id. I just want that, whether the Radio Button "Edit Only this Occurrence" will be hidden and by default the Radio Button "Edit the series" is selected. so that it gets the id of appointment. Please help me, Its urgent.
0
Shinu
Top achievements
Rank 2
answered on 25 Sep 2013, 12:09 PM
Hi Kalpna,

Please try the following JavaScript in the OnClientAppointmentContextMenuItemClicked client event of the RadScheduler.

JavaScript:
<script type="text/javascript">
    function OnClientAppointmentContextMenuItemClicked(sender, eventArgs) {
        $telerik.$('.rsModalContent').children().first().hide();
        $telerik.$('#choiceOccurrenceSpan_1').attr('checked', 'checked');
    }
</script>

Thanks,
Shinu.
0
Kalpna
Top achievements
Rank 1
answered on 02 Oct 2013, 01:03 PM
Thanks Shinu,

But it does not do anything. Is there any way, when we double clicks on an recurring activity, then window does not show Edit only this occurrence button, it shows only Edit the Series. And it is by default selected.
Tags
Calendar
Asked by
Kalpna
Top achievements
Rank 1
Answers by
Shinu
Top achievements
Rank 2
Kalpna
Top achievements
Rank 1
Share this question
or