This is a migrated thread and some comments may be shown as answers.

Weekend Color

17 Answers 247 Views
Scheduler
This is a migrated thread and some comments may be shown as answers.
Susan
Top achievements
Rank 1
Susan asked on 24 Feb 2008, 12:50 AM
I am using the WebBlue skin, but my user wants the weekend color shaded darker. I added the following to my aspx:

.RadScheduler_WebBlue .rsContentTable .rsSatCol,

.RadScheduler_WebBlue .rsContentTable .rsSunCol

{

background:#8B8F91;

border-bottom-color:#d2d8db;

}

When first entring the screen, it is still the light blue. If I change to 24-hour, it is the new dark grey I specified. If I change back to Business Hours, it is then changed to the Dark Grey. How do I get the Dark Grey to show when I first enter the screen for the first time?

Thanks,
Susan

17 Answers, 1 is accepted

Sort by
0
Accepted
Peter
Telerik team
answered on 25 Feb 2008, 02:20 PM
Hello Susan,

The specificity of the selectors you use is not enough for the new rule to overwrite the existing one. Please, try the following selectors which have greater specificity:
.rsContent .rsContentTable .rsRow .rsSatCol,  
         .rsContent .rsContentTable .rsRow .rsSunCol   
        {  
          background:#8B8F91;  
          border-bottom-color:#d2d8db;  
        } 


All the best,
Peter
the Telerik team

Instantly find answers to your questions at the new Telerik Support Center
0
Susan
Top achievements
Rank 1
answered on 25 Feb 2008, 05:31 PM
Worked great...thanks.
0
Ilya
Top achievements
Rank 1
answered on 15 Sep 2011, 05:11 PM
I am having a similar issue which was not corrected after using the css above. When the page loads the weekends are light blue in color but they are shown dark grey when I switch to a month view. What could be a problem? Thanks
0
Ilya
Top achievements
Rank 1
answered on 15 Sep 2011, 05:31 PM
Ok it looks like the following css works. However, it does nto change the all day background color. How can that be accomplished? Thanks

div.RadScheduler_Web20 .rsSatCol, 
div.RadScheduler_Web20 .rsSunCol  
        
          background-color: #C9CFD6
          border-bottom-color: #d2d8db
        }
0
Princy
Top achievements
Rank 2
answered on 16 Sep 2011, 10:07 AM
Hello Ilya,

I suppose you want to change the background color of allday rows in MonthView.Try the following CSS to achieve your scenario.
CSS:
<style type="text/css">
 .rsContent .rsContentTable .rsRow, .rsSunCol, .rsSatCol 
 
   background:red !important
 }
</style>

Thanks,
Princy.
0
Ilya
Top achievements
Rank 1
answered on 16 Sep 2011, 02:42 PM
Hi Princy,

Thanks for your reply but I actually I wanted to change the color of all day in the WeekView.
0
Shinu
Top achievements
Rank 2
answered on 17 Sep 2011, 05:02 AM
Hello Ilya,

Try the following CSS to change the color of all day in WeekView.
CSS:
<style type="text/css">
.RadScheduler .rsAllDayRow td
 {
   background-color:Red !important;
 }
</style>

Thanks,
Shinu.
0
Ilya
Top achievements
Rank 1
answered on 19 Sep 2011, 03:07 PM
Shinu, I only need different color on Saturdays and Sundays. I've tried

div.RadScheduler_Web20 .rsAllDayRow .rsSatCol


but it does not work.
0
Shinu
Top achievements
Rank 2
answered on 20 Sep 2011, 06:34 AM
Hello Ilya,

Try the folllowing CSS to change the color of Saturdays and Sundays in WeekView.
CSS:
<style type="text/css">
 .RadScheduler_Web20 .rsSunCol, .rsSatCol
 {
   background-color:Red !important;
 }
</style>

Thanks,
Shinu.
0
Ilya
Top achievements
Rank 1
answered on 20 Sep 2011, 01:55 PM
Shinu,

I need to change background of ALL Day cells on Saturdays and Sundays in Week View. 

Thanks
0
Stuart Hemming
Top achievements
Rank 2
answered on 20 Sep 2011, 03:05 PM
Ilya,

You're a little out of luck as the scheduler, out-of-the-box, doesn't apply the day classes to the all day row.

All is not lost though. If you wire up the TimeSlotCreated event you can do this ...

protected void RadSceduler1_TimeSlotCreated(object sender, TimeSlotCreatedEventArgs e)
{
  if(e.TimeSlot.Start.DayOfWeek == DayOfWeek.Saturday)
  {
    e.TimeSlot.CssClass = "rsSat";
  }
  if(e.TimeSlot.Start.DayOfWeek == DayOfWeek.Sunday)
  {
    e.TimeSlot.CssClass = "rsSun";
  }
}

 
Then, CSS selector you want is...

.RadScheduler_Web20 .rsAllDayRow .rsSat, .RadScheduler_Web20 .rsAllDayRow .rsSun,

-- 
Stuart
0
Ilya
Top achievements
Rank 1
answered on 20 Sep 2011, 03:18 PM
Thanks Stuart, it worked. Is there a place where I can get more information about RadScheduler CSS (like sSatCol, rsAllDayRow, etc)? I can't seem to find any documentation about it.

By the way here is what I did:

<style type="text/css">
   .AllDayWeekend
    {
       background: #A9A9A9;
    }
</style>

And in TimeSlotCreated event (VB)

If e.TimeSlot.Start.DayOfWeek = DayOfWeek.Saturday Or e.TimeSlot.Start.DayOfWeek = DayOfWeek.Sunday Then
            e.TimeSlot.CssClass = "AllDayWeekend"
End If
0
Stuart Hemming
Top achievements
Rank 2
answered on 20 Sep 2011, 03:28 PM
Ilya,

Sadly, there's nothing in the docs. You'll have ot do what the rest of us do and that's using something like FireBug to see what's been rendered where you want to change things and then have a root about in the .css files.

-- 
Stuart
0
Stuart Hemming
Top achievements
Rank 2
answered on 20 Sep 2011, 03:29 PM
Ilya,

Don't forget to mark the question as answered.

-- 
Stuart
0
Ilya
Top achievements
Rank 1
answered on 20 Sep 2011, 03:29 PM
Yeah, that's what I figured. Ok, no problem. Thanks again for pointing me in the right direction.
0
Ilya
Top achievements
Rank 1
answered on 20 Sep 2011, 03:33 PM
Hmm, I just realized that I've hijacked an old thread. If you want I can open a new thread so you can post your solution there.
0
Plamen
Telerik team
answered on 20 Sep 2011, 03:51 PM
Hello Ilya,

Here is a sample project that shows one way to do this scenario.

Hope this will help.

Regards,
Plamen Zdravkov
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
Tags
Scheduler
Asked by
Susan
Top achievements
Rank 1
Answers by
Peter
Telerik team
Susan
Top achievements
Rank 1
Ilya
Top achievements
Rank 1
Princy
Top achievements
Rank 2
Shinu
Top achievements
Rank 2
Stuart Hemming
Top achievements
Rank 2
Plamen
Telerik team
Share this question
or