Changeing row/cell backgrounds of a resource

3 posts, 0 answers
  1. MfE_Developer
    MfE_Developer avatar
    10 posts
    Member since:
    May 2011

    Posted 30 May 2011 Link to this post

    I'm trying to find a way to change the background colour of a row/cell.

    Currently, our asset booking system looks like late-current.gif - whereas the red highlighted booking indicates that that resource it is overdue and hasn't been returned. What is required is for the whole row of the timeline to turn red if the asset is overdue, as indicated in late-required.gif.

    The appointments change colour using the following code:

    protected void RadScheduler1_AppointmentDataBound(object sender, SchedulerEventArgs e)
            DateTime now = DateTime.Now;
            if (e.Appointment.Resources.GetResource("Status", 1) != null)
               e.Appointment.CssClass = "rsCategoryOrange";

    And I was trying to do something similar to change the entire row background.

    Note: all the resources are populated from the database and are not hardcoded.

    Any ideas anyone?
  2. Peter
    Peter avatar
    6637 posts

    Posted 31 May 2011 Link to this post

    Hello Mike,

    You can style the time slots conditionally based on the resource or appointments they contain. Here is a kb article that will help you get started -

    Feel free to contact us if you have further questions.

    the Telerik team

    Browse the vast support resources we have to jump start your development with RadControls for ASP.NET AJAX. See how to integrate our AJAX controls seamlessly in SharePoint 2007/2010 visiting our common SharePoint portal.

  3. MfE_Developer
    MfE_Developer avatar
    10 posts
    Member since:
    May 2011

    Posted 31 May 2011 Link to this post

    Cheers Peter,

    I found it very difficult to work out how to get resource data from the appointment - i.e. if the resource is of booked status, etc - so I just made the appointment stretch to the present time to show the asset hadn't been returned.

    Problem solved - but different method used.
Back to Top