Hide Recurrence and All Day checkboxes

9 posts, 1 answers
  1. Mark
    Mark avatar
    52 posts
    Member since:
    Sep 2007

    Posted 26 Jan 2008 Link to this post

    In the advanced edit form I want to hide the Recurring Appt and All Day Event checkboxes.  I've tried this so far, but it seems to do nothing:


    protected void RadScheduler1_AppointmentCommand(object sender, AppointmentCommandEventArgs e)

    {
        

    if (e.CommandName == "Edit")
        {
            
    CheckBox repeatCheck = (CheckBox)e.Container.FindControl("RepeatCheckBox");
            repeatCheck.Visible =
    false;
          }
    }



    Thanks for your help

  2. Answer
    Peter
    Admin
    Peter avatar
    6637 posts

    Posted 29 Jan 2008 Link to this post

    Hello Mark,

    Please, try the following code:

     protected void RadScheduler1_FormCreated(object sender, Telerik.Web.UI.SchedulerFormCreatedEventArgs e)  
        {  
            CheckBox AllDayCheckBox = (CheckBox)e.Container.FindControl("_allDayEvent");  
            AllDayCheckBox.Visible = false;  
     
            CheckBox RecurrenceCheckBox = (CheckBox)e.Container.FindControl("_recurrentAppointment");  
            RecurrenceCheckBox.Visible = false;  
        } 

    If you view the rendered html output of the advanced form, you will notice that the last underscore is doubled: "__".
    That is why we take the key word of the ID of the checkbox with a preceding underscore: "_allDayEvent". Indeed, this is hard to spot and it took us a while to figure it out. :).



    Kind regards,
    Peter
    the Telerik team

    Instantly find answers to your questions at the new Telerik Support Center
  3. Mark
    Mark avatar
    52 posts
    Member since:
    Sep 2007

    Posted 10 Feb 2008 Link to this post

    Perfect - thanks!
  4. Peter Briggs
    Peter Briggs avatar
    14 posts
    Member since:
    Mar 2010

    Posted 17 Mar 2010 Link to this post

    I also would like to hide the All Day event checkbox and have used the code example given above and it does work. However in the development environment I receive a jscript error: 0.parentNode is null or not an object on this line:

    var m=d(l[0].parentNode.parentNode.parentNode);


    Please assist.
  5. Peter
    Admin
    Peter avatar
    6637 posts

    Posted 19 Mar 2010 Link to this post

    Hi Peter,

    That approach is intended for an older version of Telerik controls. If you need to hide the all-day checkbox you can use the following css:
    .rsAllDayWrapper
        {
            visibility:hidden !important;
        }


    All the best,
    Peter
    the Telerik team

    Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items.
  6. Peter Briggs
    Peter Briggs avatar
    14 posts
    Member since:
    Mar 2010

    Posted 19 Mar 2010 Link to this post

    Thanks!
  7. Tanvir
    Tanvir avatar
    7 posts
    Member since:
    Apr 2013

    Posted 09 Jan in reply to Peter Link to this post

    How can i apply the CSS to rsAllDayWrapper to my Advance Form ?

    Thank you

  8. Tanvir
    Tanvir avatar
    7 posts
    Member since:
    Apr 2013

    Posted 09 Jan in reply to Peter Link to this post

    I would also like to hide Recurrence field from Advance Form. How can i do it ? 

    Thank you

  9. Rumen
    Admin
    Rumen avatar
    13302 posts

    Posted 10 Jan Link to this post

    Hello Tanvir,

    You can see how to customize the Advanced Form in this demo.

    Set the Visible property of the telerik:RadSchedulerRecurrenceEditor control to false, i.e.

    <telerik:RadSchedulerRecurrenceEditor runat="server" ID="AppointmentRecurrenceEditor" Visible="false" RenderMode="Lightweight" />

    For your convenience I recorded a video of how to do that and attached it my reply.

    Best regards,
    Rumen
    Progress Telerik
    Try our brand new, jQuery-free Angular components built from ground-up which deliver the business app essential building blocks - a grid component, data visualization (charts) and form elements.
Back to Top