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

ID Selector + TreeView CSS

1 Answer 50 Views
TreeView
This is a migrated thread and some comments may be shown as answers.
Eng.Bassel Samman
Top achievements
Rank 2
Eng.Bassel Samman asked on 05 Dec 2010, 01:16 PM
Dears,
I have the following CSS in Style.css file (All pages in the project have a link to Style.css file)
          .RadTreeView .rtLI
        {
            padding-bottom: 10px;
        }
        .RadTreeView .rtUL .rtUL
        {
            margin-top: 10px;
        }
        .RadTreeView .rtLast
        {
            padding-bottom: 0; /* prevent double-spacing */
        }
 

I want to apply it on one specific RadTreeView only. How can I specify the ID selector

1 Answer, 1 is accepted

Sort by
0
Accepted
Kamen Bundev
Telerik team
answered on 05 Dec 2010, 01:36 PM
Hi Bassel,

If you're using the ID of the RadTreeView then your CSS should look like this:
#YourClientID .rtLI
{
    padding-bottom: 10px;
}


However, since your ClientID is a subject to change, you can specify a CssClass to your RadTreeView and then up your selector specificity by 1 to override the internal one:
div.YourCssClass .rtLI
{
    padding-bottom: 10px;
}


Regards,
Kamen Bundev
the Telerik team
Browse the vast support resources we have to jumpstart 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.
Tags
TreeView
Asked by
Eng.Bassel Samman
Top achievements
Rank 2
Answers by
Kamen Bundev
Telerik team
Share this question
or