This is a migrated thread and some comments may be shown as answers.

RadGrid inserting styles I can't modify?

1 Answer 54 Views
Grid
This is a migrated thread and some comments may be shown as answers.
Software
Top achievements
Rank 1
Software asked on 01 Mar 2012, 09:13 PM
I just switched a fairly large, 3-year-old application to the latest version of the Ajax controls.  One of the primary screens uses a RadGrid to display search results.  After switching to the new release (we had been using 2010.3.1717.40) the RadGrid now shows a 17px wide gap on the right side of the grid (see attached).  In investigating where this was coming from, I ran the IE9 Web Developer Tools, which shows a "margin-right: 17px" on the RadGridHeader div.  Here's the HTML that shows in Web Developer Tools:
<div class="rgHeaderDiv" id="ctl00_cphDefault_RadGrid1_GridHeader" style="width: 715px; overflow: hidden; margin-right: 17px;" _events="[object Object]">
If I disable the margin-right: 17px the grid aligns perfectly.  However, I can't figure out where this is being set?  How do I change this?  I searched my entire solution and I don't have any file in it that contains that text.  However, I did find it when viewing the Telerik.Web.UI.WebResource.axd file in Web Developer Tools.  So I have to assume it's coming from there.  Please let me know how to fix this.  

Thanks for your help!
Eddie

1 Answer, 1 is accepted

Sort by
0
Tsvetina
Telerik team
answered on 07 Mar 2012, 09:01 AM
Hi Eddie,

Confirm that you are not browsing the site in Quirks mode, as this is the only scenario where we could replicate the problem that you are experiencing. This margin was added to fix an alignment issue when using static headers and if you remove it, the layout could break in other browsers.

Greetings,
Tsvetina
the Telerik team
If you want to get updates on new releases, tips and tricks and sneak peeks at our product labs directly from the developers working on the RadControls for ASP.NET AJAX, subscribe to their blog feed now.
Tags
Grid
Asked by
Software
Top achievements
Rank 1
Answers by
Tsvetina
Telerik team
Share this question
or