RadScheduler all day event display

19 posts, 1 answers
  1. Dragan
    Dragan avatar
    6 posts
    Member since:
    Jun 2009

    Posted 03 Jun 2009 Link to this post

    I have a RadScheduler set like this:
    <telerik:RadScheduler runat="server" DataEndField="EndDate"
            DataKeyField="TaskID" DataStartField="StartDate"
            DataSubjectField="Title" Skin="Web20" FirstDayOfWeek="Monday"
            LastDayOfWeek="Sunday" SelectedView="WeekView" OverflowBehavior="Expand"  
            DataSourceID="SqlDataSource1" ID="scheduler">

    and on the web page when I double click and enter the all day event which is like more than 2 words long and click to save it, it shows but it's height stays the same i.e. it does not expand. If I enter the same text on any hour event it will properly expand.

    Can somebody point me on what do I need to do to have the all day event expand so the user can see the whole text entered?

    Thank you,
    Dragan B.



  2. Dragan
    Dragan avatar
    6 posts
    Member since:
    Jun 2009

    Posted 03 Jun 2009 Link to this post

    forgot to mention that I saw people mentioning using rsAllDayHeader and rsAllDayTable but that only deals with the table not the entry itself. It would be usefull if somebody could tell me the name of the style that controls this.
  3. Dragan
    Dragan avatar
    6 posts
    Member since:
    Jun 2009

    Posted 03 Jun 2009 Link to this post

    they say that picture tells more than thousand words
    click here to see the picture
  4. Peter
    Admin
    Peter avatar
    6637 posts

    Posted 03 Jun 2009 Link to this post

    Hi Dragan,

    Automatic appontment height to wrap the entire text of the apointment is not supported. You can either set the RowHeight or ColumnWidth property or use both of these to allow more viewable area for the appointments.


    Regards,
    Peter
    the Telerik team

    Instantly find answers to your questions on the new Telerik Support Portal.
    Check out the tips for optimizing your support resource searches.
  5. Dragan
    Dragan avatar
    6 posts
    Member since:
    Jun 2009

    Posted 03 Jun 2009 Link to this post

    Peter,

    I don't understand the 'Automatic appontment height to wrap the entire text of the apointment is not supported' part as it's visible on the picture that one appointment I made is auto extended to allow display of all of it. As soon as I drag and drop that appointment to All-day part it stops wrapping it and cuts off the half of it. If I drag and drop it back to the hours part it goes back to the extended state.

    Thank you.
  6. Answer
    Peter
    Admin
    Peter avatar
    6637 posts

    Posted 03 Jun 2009 Link to this post

    Hi Dragan,

    When you drag an appointment from the all-day row to the hours row, it defaults to one hour in duration. Since by default each row stands for 30 minutes time span, the row expands on two rows hence you get the impression that it expands to wrap the text. Actually, the length of the text is not determining the height of the appointment but its duration is. I hope this makes it clearer.


    Best wishes,
    Peter
    the Telerik team

    Instantly find answers to your questions on the new Telerik Support Portal.
    Check out the tips for optimizing your support resource searches.
  7. Dragan
    Dragan avatar
    6 posts
    Member since:
    Jun 2009

    Posted 04 Jun 2009 Link to this post

    OK, now I understand it. Thanks for the clarification.
  8. Michael J.
    Michael J. avatar
    14 posts
    Member since:
    Apr 2009

    Posted 05 Jun 2009 Link to this post

    Telerik: When you drag an appointment from the all-day row to the hours row, it defaults to one hour in duration. 

    Me: I discovered this behavior earlier today.  How, then, do you override this behavior?

    It may or may not be related, but when I drag an Appointment out of the "All Day Appointment" area into any specified "hours" area in the Scheduler's Week View, the Appointment defaults its Duration to 1 HOUR.  This behavior is expected.  However, any successive attempts to change the Appointment to any Duration that has a half HR increment(i.e. 1/2 HR or 1 1/2 HR) fails.  The e.ModifiedAppointment.End value still seems to round up to the nearest hour.  It totally ignores any half-hour increments that I've specified.

    An example would be an existing Appointment starting at 1:00 PM and ending at 2:00 PM.  If I drag the Appointment to change its end to 2:30 PM, I should expect to then see an Appointment starting at 1:00 PM and ending at 2:30 PM.  Instead, I'm seeing an Appointment that starts at 1:00 PM and ending at 3:00 PM.

    Any suggestions?  As always, thanks for the help!

    Thanks!
  9. Peter
    Admin
    Peter avatar
    6637 posts

    Posted 08 Jun 2009 Link to this post

    Hi Michael J.,

    To override this behavior, please handle AppointmentUpdate as follows:
    protected void RadScheduler1_AppointmentUpdate(object sender, AppointmentUpdateEventArgs e)  
        {  
            if(e.Appointment.Duration.TotalHours >= 24)  
                e.ModifiedAppointment.End = e.ModifiedAppointment.Start.AddHours(0.5);  
        } 

    This code checks if the appointment is all day and if it is, makes its duration half an hour when dragged to an hour row.

    Please, let us know if you continue to experience problems with this case.


    Regards,
    Peter
    the Telerik team

    Instantly find answers to your questions on the new Telerik Support Portal.
    Check out the tips for optimizing your support resource searches.
  10. Connections Academy Developer
    Connections Academy Developer avatar
    63 posts
    Member since:
    May 2005

    Posted 02 Jun 2010 Link to this post

    Hi -

    I am using v2009.2.826.35 of the Telerik.Web.UI DLL and working with the RadScheduler.  I was wondering if, per your previous comment, there is an easy way to get/set (on the server side) whether or not a particular appointment is an all-day appointment.  I am seeing this article which shows the use of an IsAllDayEvent property of the Appointment class, however that doesn't appear to be available in my version.  I also see here that there is a CLIENT-SIDE function, get_isAllDay(), for accomplishing this.  Is there nothing like this in the server-side API?

    Thanks.
  11. Peter
    Admin
    Peter avatar
    6637 posts

    Posted 03 Jun 2010 Link to this post


    The documentation which you have seen is for WPF RadScheduler, not for ASP.NET AJAX. For the latter RadScheduler there isn't a server side property to indicate if an appointment is an all-day appointment or not. Do you experience any problems with the workaround I suggested?


    Best wishes,
    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.
  12. Connections Academy Developer
    Connections Academy Developer avatar
    63 posts
    Member since:
    May 2005

    Posted 04 Jun 2010 Link to this post

    I am a little confused about how an event's duration being >= 24 hours is an indicator that it is an all-day event.  What if it is a 3-day event, from 1pm on the first day to 11am on the third day?  That would be an event with specific start/end times, and a duration greater than 24 hours.  Am I missing something about the Duration property?
  13. Peter
    Admin
    Peter avatar
    6637 posts

    Posted 07 Jun 2010 Link to this post


    I see what you mean and you are right. Please, excuse me for the misleading suggestion. Here is a revised version for how to check if an appointment is allday or not:
    protected void RadScheduler1_AppointmentDataBound(object sender, SchedulerEventArgs e)
       {
           if (e.Appointment.Start.TimeOfDay == new TimeSpan(0) & e.Appointment.End.TimeOfDay == new TimeSpan(0) & e.Appointment.Duration.TotalHours == 24)
               Response.Write(e.Appointment.Subject + "- is all day app </br>");
       }
     

    Kind regards,
    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.
  14. Connections Academy Developer
    Connections Academy Developer avatar
    63 posts
    Member since:
    May 2005

    Posted 07 Jun 2010 Link to this post

    Thanks.  I am assuming the line that says "== 24" is supposed to say ">=24".  Is there any plan to incorporate this as an actual server-side property?  It seems like a pretty fundamental property of an event, not to mention the fact that the WPF version exposes such a property AND there is already a corresponding client-side approach.
  15. Peter
    Admin
    Peter avatar
    6637 posts

    Posted 08 Jun 2010 Link to this post


    The duration of all-day appointments is exactly 24 hours so the '==' check is correct.

    Yes, we have plans to implement such a property in the future, but I cannot say exactly when this will happen at the moment.


    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.
  16. Preethi
    Preethi avatar
    10 posts
    Member since:
    Aug 2011

    Posted 08 Sep 2011 Link to this post

    Hi,
        I am using Radschduler and am facing a problem with the All Day Row.
    When I add an all dat event or as soon as I drag and drop that appointment to All-day part it stops wrapping it and cuts off the half of it.
    I want to display the text to span the whole of the All Day row.(in my case the text is getting truncated)
    Any insight on this?

    Regards,
    Preethi D
  17. Peter
    Admin
    Peter avatar
    6637 posts

    Posted 13 Sep 2011 Link to this post

    Hi Preethi,

    Please, try the following css workaround:
    .rsAllDayRow .rsApt, .rsAllDayRow .rsAptOut
      
        {
      
            height: 45px !important;
      
        }
      
        .rsAllDayRow
      
        {
      
            height: 100px !important;
      
        }


    Greetings,
    Peter
    the Telerik team

    Check out Telerik Trainer, the state of the art learning tool for Telerik products.
  18. Slava
    Slava avatar
    11 posts
    Member since:
    Jan 2011

    Posted 31 Dec 2017 in reply to Peter Link to this post

    if it's a 2 day "all day" event then it would be 48 hours, so this condition "& e.Appointment.Duration.TotalHours == 24" won't work...
  19. Marin Bratanov
    Admin
    Marin Bratanov avatar
    4128 posts

    Posted 02 Jan Link to this post

    Hi Slava,

    You can change the condition to fit your needs, for example, to ">=24", as was suggested earlier.

    Regards,

    Marin Bratanov
    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