RadScheduler InsertAppointment not firing when calling from code behind

3 posts, 0 answers
  1. Ei Wai
    Ei Wai avatar
    56 posts
    Member since:
    Jul 2014

    Posted 25 Jan 2015 Link to this post

    Hi ,

    I am using Inline template to insert data. There are two command button which is Insert and Update.  To insert appointment, I am trying to call  Insert Appointment method inside RadScheduler1_AppointmentCommand. My code is as below.

    Appointment apptForInsert = e.Container.Appointment;
    RadScheduler1.InsertAppointment(apptForInsert);
    RadScheduler1.Rebind();

    By right, it should go to RadScheduler1_AppointmentInsert() method. But it didn't and the inline template form also not closed after all the events fired. Please help me with this issue. 

    And there is also another problem I would like to ask. Is there any way to call RadScheduler1_AppointmentCommand from the javascript? I know I can call insertAppointment using javascript. But I am looking for a way to call AppointmentCommand.



    Thank you.

    Best regards,
    Ei Wai

  2. Boyan Dimitrov
    Admin
    Boyan Dimitrov avatar
    1746 posts

    Posted 28 Jan 2015 Link to this post

    Hello Ei,

    As far as I understand when you click on the insert button it goes in the AppointmentCommand event handler but it does not execute the InsertAppointment method. Is this correct?
    Could you please specify whether the appointment is added to the data source?

    Our RadScheduler Templates demo implements custom inline form containing buttons with insert and update commands.
    As you can see in the AppointmentCommand event handler there is no need to insert the appointment explicitly as soon as there is an insert command associated with the button.  Same thing applies for the update button.

    There is no way to call RadScheduler1_AppointmentCommand from the JavaScript.

    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.

     
  3. UI for ASP.NET Ajax is Ready for VS 2017
  4. Ei Wai
    Ei Wai avatar
    56 posts
    Member since:
    Jul 2014

    Posted 28 Jan 2015 in reply to Boyan Dimitrov Link to this post

    Hello Boyan,

    Thank you for your reply. It is solved by adding validation group in the button properties. I am not sure why. 

    Best regards,
    Ei Wai
Back to Top