GridView AllowFilteringbyColumn causing UI Issues.

0 Answers 103 Views
Filter Grid
Roger
Top achievements
Rank 2
Iron
Iron
Iron
Roger asked on 11 Aug 2022, 02:07 PM | edited on 11 Aug 2022, 02:41 PM

I have a RadGridView that fits my page as expected utilizing the width property.

But when I set the AllowFilteringByColumn to "True" the grid now expands past the width property.

It first draws on the screen in proper width, then at the end expands way past width.

 

Using Version 2019.2.514.40

 

I have tried setting render mode to "Classic", "Lightweigt" but get exact same problem.

 

See picture below.  You can see all columns when I set to False, but when I set to True, you cannot see all columns, you

now have to scroll a lot to see them all.

 

Rumen
Telerik team
commented on 16 Aug 2022, 09:18 AM

Hi Roger,

Your question is answered in this StackOverflow discussion - https://stackoverflow.com/questions/11268881/how-to-control-the-width-of-radgrid. You need to set the width on individual columns.

Can you also reduce the columns and filters width so that all columns get shown on the page:

  • Specify the width of the filter elements like this:

    <style type="text/css">
        /* make the html elements fit only the 90% of the Grid Cell */
        html body .RadGrid .rgFilterRow .RadInput,
        html body .RadGrid .rgFilterRow .RadPicker,
        html body .RadGrid .rgFilterRow .rgFilterBox {
            width: 90%;
        }
    </style>
    You can do it also programmatically as shown here and here.

  •  Decrease the column width using the HeaderStyle-Width="100px" property.
  • You can also test with TableLayout="Fixed" in the MasterTableView declaration.

Last but not least you can test with Width="100%" set in the RadGrid declaration.

 

If you are unable to solve the issue, please isolate it in a simple runnable project with a dummy datasource and send it for examination. 

Please also make a quick Fiddler Jam Chrome Extension capture and share it with us. It will provide a lot of info easily and allow us to investigate further. Keep in mind that starting from a blank page or at least navigating to your page via the address bar is crucial for capturing all requests and responses:

https://docs.telerik.com/devtools/aspnet-ajax/knowledge-base/common-capture-issues-with-fiddler-jam 

No answers yet. Maybe you can help?

Tags
Filter Grid
Asked by
Roger
Top achievements
Rank 2
Iron
Iron
Iron
Share this question
or