Hyperlink to open Advanced Forms

4 posts, 1 answers
  1. Ilya
    Ilya avatar
    67 posts
    Member since:
    Jul 2012

    Posted 22 Sep 2011 Link to this post

    I have created a custom appointment template which contains a hyperlink. is there a way to open an AdvancedEdit form by clicking on that hyperlink?

    Thanks
  2. Answer
    Peter
    Admin
    Peter avatar
    6637 posts

    Posted 23 Sep 2011 Link to this post

    Hi Ilya,

    Please, try the following code:
    <script type="text/javascript">
     
           var flag = false;
     
           function EditAppointment(e) {
               flag = true;
           }
           function OnClientAppointmentClick(sender, args) {
               if (flag) {
                   sender.editAppointmentWithConfirmation(args.get_appointment());
                   flag = false;
               }
           }
       </script>
       <telerik:RadScheduler runat="server" ID="RadScheduler1" OnClientAppointmentClick="OnClientAppointmentClick">
           <AppointmentTemplate>
               <%#Eval("Subject") %>
               <hr />
               <a href="#" onclick="EditAppointment(event)">edit</a>
           </AppointmentTemplate>
       </telerik:RadScheduler>


    Kind regards,
    Peter
    the Telerik team
    If you want to get updates on new releases, tips and tricks and sneak peeks at our product labs directly from the developers working on the RadControls for ASP.NET AJAX, subscribe to their blog feed now
  3. Jayesh Goyani
    Jayesh Goyani avatar
    2733 posts
    Member since:
    May 2010

    Posted 23 Sep 2011 Link to this post

    Hello,

      protected void btnAddAppointment_Click(object sender, EventArgs e)
        {
            RadScheduler1.ShowAdvancedInsertForm(RadScheduler1.SelectedDate);
        }


    Thanks
    Jayesh Goyani
  4. Ilya
    Ilya avatar
    67 posts
    Member since:
    Jul 2012

    Posted 23 Sep 2011 Link to this post

    Ok, it works great. Thanks
Back to Top