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

Error when moving recurring appointment

3 Answers 58 Views
General Discussions
This is a migrated thread and some comments may be shown as answers.
Robbie
Top achievements
Rank 1
Robbie asked on 28 Jan 2015, 09:37 AM
I'm not really sure if it's my fault (am I overlooking something?), but when I move an appointment that's part of a recurrence the advanced popup shows asking me if I want to replace the entire recurrence or just this one.

After that an error is thrown telling me that 'this' does not contain a method called 'get_owner'.
The Telerik.Web.UI dll's are on version 2014.2.724.40 and the project is an ASP.NET project.

The error occurs in a dynamic blank script and looks like this:

_onAppointmentMoveCallback:function(j,h)
    {
        h.Scheduler._raiseRecurrenceActionDialogClosedEvent(h,false,b.RecurrenceAction.Move);
        var k={
            appointment: h.Appointment,
            newStartTime: h.NewStart,
            editingRecurringSeries:j,
            targetSlot:h.TargetSlot,
            isAbortedByUser:false
        };
        var i=a.raiseCancellableControlEvent(h.Scheduler,"appointmentMoveEnd",k);
        if((this.get_owner().get_groupBy()!==g) &&
            this.get_owner()._webServiceSettings.get_isEmpty() &&
            h.Appointment.get_resources().indexOf(h.SourceSlot.get_resource())==-1)
        { i=true; }
        if(!i) {
            h.Scheduler.moveAppointment(h.Appointment,j,h.SourceSlot,h.TargetSlot);
        } else {
            h.Appointment._abortDrag();
        }
    }

The debugger stops and tells me that this.get_owner() does not exist.
If there's any more information you need, please let me know.

3 Answers, 1 is accepted

Sort by
0
Boyan Dimitrov
Telerik team
answered on 02 Feb 2015, 08:47 AM
Hello,

We are not aware of such problem. In order to investigate this behavior we would need your RadScheduler mark-up code.

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.

 
0
Robbie
Top achievements
Rank 1
answered on 06 Mar 2015, 12:31 PM
I unserstand, this is the RadScheduler.

<
telerik:RadScheduler ID="RadScheduler1" runat="server" OnClientAppointmentClick="OnClientAppointmentClick"
    OnClientTimeSlotClick="OnClientTimeSlotClick" Height="100%"
    Culture="nl-NL" EnableDescriptionField="True"
    FirstDayOfWeek="Monday" LastDayOfWeek="Sunday" StartInsertingInAdvancedForm="True"
    HoursPanelTimeFormat="HH:mm" DisplayRecurrenceActionDialogOnMove="True" ShowNavigationPane="False"
    GroupBy="Cliënt" OnTimeSlotCreated="RadScheduler1_TimeSlotCreated" OnClientAppointmentContextMenu="OnClientAppointmentContextMenu"
    OnAppointmentDataBound="RadScheduler1_AppointmentDataBound"
    OnAppointmentDelete="RadScheduler1_AppointmentDelete"
    OnAppointmentInsert="RadScheduler1_AppointmentInsert" OnAppointmentUpdate="RadScheduler1_AppointmentUpdate"
    OnAppointmentCreated="RadScheduler1_AppointmentCreated" OnClientFormCreated="schedulerFormCreated"
    OnDataBinding="RadScheduler1_DataBind"
    OnDataBound="RadScheduler1_DataBound" AppointmentStyleMode="Default" DataKeyField="ndClientafspraak"
    DataStartField="ddStart" DataEndField="ddEind" DataSubjectField="sdOnderwerp"
    DataDescriptionField="sdOmschrijving" DataRecurrenceField="RecurrenceRule" DataRecurrenceParentKeyField="RecurrenceParentID"
    OnFormCreated="RadScheduler1_FormCreated" CustomAttributeNames="idGroepafspraak,bdParamedici"
    OnClientAppointmentEditing="OnClientAppointmentEditing"
    OnClientAppointmentDeleting="OnClientAppointmentDeleting"
    OnClientAppointmentMoveStart="OnClientAppointmentMoveStart"
    OnClientRecurrenceActionDialogShowing="OnClientRecurrenceActionDialogShowing"
                         
    OnClientAppointmentContextMenuItemClicking= "OnClientAppointmentContextMenuItemClicking"
    EditFormTimeFormat="HH:mm" ResolvedRenderMode="Classic">
    <AdvancedForm DateFormat="dd-MM-yyyy" TimeFormat="HH:mm" MaximumHeight="700px" Modal="True" />
    <AdvancedEditTemplate>
        <scheduler:AdvancedForm runat="server" ID="AdvancedEditForm1" Mode="Edit" Subject='<%# Bind("Subject") %>'
            Description='<%# Bind("Description") %>' Start='<%# Bind("Start") %>' End='<%# Bind("End") %>'
            RecurrenceRuleText='<%# Bind("RecurrenceRule") %>' ndClient='<%# Bind("Cliënt")  %>'
            ndCategorie='<%# Bind("Categorie") %>' AppointmentId='<%# Bind("ID") %>' />
    </AdvancedEditTemplate>
    <AdvancedInsertTemplate>
        <scheduler:AdvancedForm runat="server" ID="AdvancedInsertForm1" Mode="Insert" Subject='<%# Bind("Subject") %>'
            Start='<%# Bind("Start") %>' End='<%# Bind("End") %>' Description='<%# Bind("Description") %>'
            RecurrenceRuleText='<%# Bind("RecurrenceRule") %>' ndClient='<%# Bind("Cliënt") %>'
            ndCategorie='<%# Bind("Categorie") %>' />
    </AdvancedInsertTemplate>
    <ResourceTypes>
        <telerik:ResourceType ForeignKeyField="ndClient" KeyField="ndClient" Name="Cliënt"
            TextField="Cliënt" AllowMultipleValues="true" />
        <telerik:ResourceType ForeignKeyField="ndClientagendaCategorie" KeyField="ndClientagendaCategorie"
            Name="Categorie" TextField="Categorie"/>
        <telerik:ResourceType ForeignKeyField="ndClientagendaCategorie" KeyField="ndClientagendaCategorie"
            Name="CategorieNoParamedici" TextField="Categorie"/>
    </ResourceTypes>
    <Localization AdvancedAllDayEvent="Hele dag" AdvancedCalendarCancel="Annuleer" AdvancedCalendarToday="Vandaag"
        AdvancedClose="Sluit" AdvancedDaily="Dagelijks" AdvancedDay="Dag" AdvancedDays="Dagen"
        AdvancedDescription="Omschrijving" AdvancedDone="Gedaan" AdvancedEditAppointment="Wijzig afspraak"
        AdvancedEndAfter="Eindigt na" AdvancedEndByThisDate="Eindigt op" AdvancedEndDateRequired="Einddatum is verplicht"
        AdvancedEndTimeRequired="Eindtijd is verplicht" AdvancedEvery="Elke" AdvancedEveryWeekday="Elke werkdag"
        AdvancedFirst="Eerste" AdvancedFourth="vierde" AdvancedFrom="Starttijd" AdvancedHourly="Uur"
        AdvancedHours="uren" AdvancedInvalidNumber="Incorrect getal" AdvancedLast="laatste"
        AdvancedMaskDay="dag" AdvancedMaskWeekday="werkdag" AdvancedMaskWeekendDay="weekend"
        AdvancedMonthly="Maandelijks" AdvancedMonths="maanden" AdvancedNewAppointment="Nieuwe afspraak"
        AdvancedNoEndDate="Geen einddatum" AdvancedOccurrences="keer" AdvancedOf="van"
        AdvancedOfEvery="van elke" AdvancedRecurEvery="Keert elke" AdvancedRecurrence="Terugkeerpatroon"
        AdvancedReset="reset uitzonderingen" AdvancedSecond="seconde" AdvancedStartDateRequired="Startdatum is verplicht"
        AdvancedStartTimeBeforeEndTime="Starttijd moet de eindtijd liggen" AdvancedStartTimeRequired="Starttijd is verplicht"
        AdvancedSubject="Onderwerp" AdvancedSubjectRequired="Vul een onderwerp in" AdvancedThe="De"
        AdvancedThird="derde" AdvancedTo="Eindtijd" AdvancedWeekly="Wekelijks" AdvancedWorking="Bezig..."
        AdvancedYearly="Jaarlijks" AllDay="hele dag" Cancel="Annuleer" ConfirmCancel="Annuleer"
        ConfirmDeleteText="Weet u zeker dat u deze afspraak wil verwijderen?" ConfirmDeleteTitle="Verwijderen"
        ConfirmRecurrenceDeleteOccurrence="Verwijder alleen dit exemplaar." ConfirmRecurrenceDeleteSeries="Verwijder de reeks."
        ConfirmRecurrenceDeleteTitle="Verwijder terugkerende afspraak" ConfirmRecurrenceEditOccurrence="Wijzig alleen dit exemplaar."
        ConfirmRecurrenceEditSeries="Wijzig de reeks." ConfirmRecurrenceEditTitle="Wijzig de terugkerende afspraak"
        ConfirmRecurrenceMoveOccurrence="Verplaats alleen dit exemplaar." ConfirmRecurrenceMoveSeries="Verplaats de reeks."
        ConfirmRecurrenceMoveTitle="Verplaats terugkerende afspraak" ConfirmRecurrenceResizeOccurrence="Verander alleen dit exemplaar."
        ConfirmRecurrenceResizeSeries="Verander de serie." ConfirmRecurrenceResizeTitle="Verander terugkerende afspraak"
        ConfirmResetExceptionsText="Wilt u alle uitzonderingen op het terugkeerpatroon verwijderen?"
        ContextMenuAddAppointment="Nieuwe afspraak" ContextMenuAddRecurringAppointment="Nieuw terugkerende afspraak"
        ContextMenuDelete="Verwijder" ContextMenuEdit="Wijzig" ContextMenuGoToToday="Ga naar vandaag"
        HeaderDay="Dag" HeaderMonth="Maand" HeaderNextDay="Volgende dag" HeaderPrevDay="Vorige dag"
        HeaderTimeline="Tijdlijn" HeaderToday="vandaag" Reminder="Herinnering" ReminderBeforeStart="voor starttijd"
        ReminderDay="dag" ReminderDays="dagen" ReminderDismiss="Verwijder" ReminderDismissAll="Verwijder alles"
        ReminderHour="uur" ReminderHours="uren" ReminderMinute="minuut" ReminderMinutes="minuten"
        ReminderNone="Niets" ReminderOpenItem="Open afspraak" ReminderOverdue="te laat"
        Reminders="Herinnering" ReminderSnooze="Uitstellen" ReminderSnoozeHint="Klik op uitstellen om herinnert te worden over:"
        ReminderWeeks="weeken" Save="Opslaan" Show24Hours="Toon 24 uren..." ShowAdvancedForm="Opties"
        ShowBusinessHours="Toon werkuren..." ShowMore="Meer..." />
    <TimelineView GroupBy="Cliënt" GroupingDirection="Vertical" SlotDuration="00:30:00"
        NumberOfSlots="48" ColumnHeaderDateFormat="HH:mm" UserSelectable="True" EnableExactTimeRendering="True"
        ShowInsertArea="False" />
    <WeekView ColumnHeaderDateFormat="dddd" />
    <DayView HeaderDateFormat="dddd, dd-MM-yyyy" />
    <MonthView ColumnHeaderDateFormat="dddd" FirstDayHeaderDateFormat="dd MMM" HeaderDateFormat="MMMM, yyyy" />
    <AppointmentContextMenuSettings EnableDefault="True" />
    <TimeSlotContextMenuSettings EnableDefault="True" />
</telerik:RadScheduler>

And this is the event handler for 

function OnClientAppointmentMoveStart(sender, eventArgs) {
     var afspraak = eventArgs.get_appointment();
}

No rocket science here I guess.
I just can't begin to comprehend how I should be able to find anything that could relate to this exception.
0
Boyan Dimitrov
Telerik team
answered on 11 Mar 2015, 09:54 AM
Hello,

This issue should be resolved in our latest official release. In order to avoid that error move appointments without any issue please update to Q1 2015(2015.1.225). 

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
General Discussions
Asked by
Robbie
Top achievements
Rank 1
Answers by
Boyan Dimitrov
Telerik team
Robbie
Top achievements
Rank 1
Share this question
or