DropDownWidth vs CheckBoxList line breaks

4 posts, 0 answers
  1. bobobio
    bobobio avatar
    3 posts
    Member since:
    May 2007

    Posted 25 Apr 2008 Link to this post


    I have a CheckBoxList control within a RadComboBox. The code in my aspx is as follows:


    radC:RadComboBox ID="NursingStatusRCB" runat="server" Width="185px" Height="100%" Skin="WebBlue">
       <radC:RadComboBoxItem runat="server" Text="Status (APN, RN, etc.)" />
    <div onclick="stopPropagation(event);">
    <asp:CheckBoxList ID="NursingStatusCBL" runat="server" CssClass="field_box" BorderStyle="None"></asp:CheckBoxList>

    In my code behind, I bind a datatable to the checkboxlist.
    When the text associated with a checkbox is wider than that provided by the dropdown, it breaks onto a new line. The second line of text is aligned underneath the checkbox. The problem is that this doesn't look good at all, so we want to have the second line of text line up with the first line of text. Can anyone offer help on how to have the text line up with itself in this manner?

    Alternatively, we could adjust the width of the DropDown of the radComboBox (using DropDownWidth) to allow enough room for the text so it doesn't break onto 2 lines. The problem we face there though is that the data populating the CheckBoxList comes from our DB, so at design time, we don't know what the width of the box needs to be. I tried setting this value as 100%, but it gets interpreted as 100px.

    Thanks for any assistance you can provide.

  2. Veselin Vasilev
    Veselin Vasilev avatar
    2992 posts

    Posted 28 Apr 2008 Link to this post

    Hello Karl,

    I noticed that you have posted the same question in ticket #134518. I have already answered there. That is why I am closing this ticket.

    Having other questions - do not hesitate to contact us again.

    the Telerik team

    Instantly find answers to your questions at the new Telerik Support Center
  3. saravanakumar
    saravanakumar avatar
    1 posts
    Member since:
    May 2011

    Posted 16 May 2011 Link to this post

    I  am having checkbox list .One of the checkboxes having more charcters.In that time the line will break,so in that situation the second line should start where the first line charcter starts.Please any one help for this
  4. Kate
    Kate avatar
    1898 posts

    Posted 19 May 2011 Link to this post

    Hi saravanakumar,

    Can you please specify which of the Telerik controls do you refer to since we do not have a checkbox list.?

    Best wishes,
    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.

Back to Top