Search code examples
asp.netvb.nettelerikradgrid

RadGrid - filter textboxs, any way to control their width dynamically?


I have a RadGrid with a filtercontrol on it. The grid fits the size of the window, but certain views have quite a few columns and when the columns get shrunk down, the filter controls don't resize to fit. Is there any way to set those filter controls to auto fix within the width of the column?

filter


Solution

  • You might take a look at column editors. I think they'll let you control the style of controls nested in the grid from outside of the grid.

    <telerik:GridBoundColumn ColumnEditorID="TextBoxColumnEditor" ... />
    
    <telerik:GridTextBoxColumnEditor ID="TextBoxColumnEditor" runat="server">
        <TextBoxStyle Width="500" />
    </telerik:GridTextBoxColumnEditor>
    

    Here's a link that explains it in detail:

    http://www.telerik.com/help/aspnet/grid/grdstylingthroughdeclarativecustomeditors.html