Telerik UI for ASP.NET AJAX

This appearance customization is not supported out-of-the-box in the current version of Telerik RadGrid. However, there is a workaround which you can apply to prevent the wrapping for column cells content. Set the DataFormatString property for each column to <nobr>{0}</nobr>. Thus the column(s) in your grid instance should stretch to fit the width of the longest text inside the column(s) cells.

For declarative columns the code be as below:

<telerik:RadGrid ID="RadGrid1" runat="server">
  <MasterTableView AutoGenerateColumns="false">
    <telerik:GridBoundColumn UniqueName="ContactName" HeaderText="Contact name" DataField="ContactName"
      DataFormatString="<nobr>{0}</nobr>" />
    <telerik:GridBoundColumn UniqueName="ContactTitle" HeaderText="Contact title" DataField="ContactTitle"
      DataFormatString="<nobr>{0}</nobr>" />
    <telerik:GridBoundColumn UniqueName="CompanyName" HeaderText="Company name" DataField="CompanyName"
      DataFormatString="<nobr>{0}</nobr>" />
    <telerik:GridBoundColumn UniqueName="Country" HeaderText="Country" DataField="Country"
      DataFormatString="<nobr>{0}</nobr>" />
    <telerik:GridBoundColumn UniqueName="City" HeaderText="City" DataField="City" DataFormatString="<nobr>{0}</nobr>" />

For auto-generated column subscribe to the ColumnCreated event and set the DataFormatString in the corresponding handler:

In the code-behind (just data-binding):


This functionality is not supported with static headers (UseStaticHeaders = true) and column resizing. With static headers the cell content will be clipped if you resize a column to make its width dimension smaller than the longest cell data.