New to Telerik UI for ASP.NET AJAX? Download free 30-day trial

Adding a Label

As of Q1 2010 release, it is easy to attach a label to RadComboBox control: simply set the text of the label as the value of the Label property. The label automatically appears to the left of the input area:

ComboBox With Label

The look of the label text is determined by the Skin property of the RadComboBox control. When you set the Skin property, the LabelCssClass property is automatically set to "rcbLabel". This value is the CSS style that the skin applies to the label. You can substitute your own CSS class to change the appearance of the label by setting the LabelCssClass property.

This is shown in the following example:

<style type="text/css">
        color: Red;
        <telerik:RadComboBoxItem runat="server" Text="RadComboBoxItem1" Value="RadComboBoxItem1" />        
        <telerik:RadComboBoxItem runat="server" Text="RadComboBoxItem2" Value="RadComboBoxItem2" />        
        <telerik:RadComboBoxItem runat="server" Text="RadComboBoxItem3" Value="RadComboBoxItem3" />    

And the result is:

ComboBox Label Changed

In this article