Sunday, January 13, 2008

Why does Firefox ignore the ASP.NET GridView border property?

By default, ASP.NET GridView comes with border property equal to null. So, you can see the vertical and horizontal lines in GridView. No matter about the browser type, it shows correctly. But if you set the GridView border property to zero (border=”0”), it will behave differently in Microsoft IE and Firefox web browsers. Because, Microsoft IE shows the GridView without borders, but Firefox shows the same GridView with borders even border=”0”. Simply Firefox ignore the ASP.NET GridView border property.

FAQ00013_1

Anyway, if we really want to hide the ASP.NET GridView gridlines inside Firefox web browser, we can do it without playing with CSS. Simply we have to set the GirdView GridLines = “None”. Because, by default GridLInes property comes with “Both” value. So, it shows the horizontal and vertical lines inside the ASP.NET GridView.

FAQ00013_2

Labels:

2 Comments:

At April 20, 2008 11:09 PM, Blogger tmasabari said...

Hi,

Thanks for valuable post. I need exactly this tip!!!

Thanks,
Sabarinathan Arthanari

 
At April 21, 2008 5:25 AM, Anonymous Jyoti Arora said...

Hi,

I would like to know how to hide columns of a gridview in a Mozilla Firefox browser. This hiding columns works fine in IE, but starts showing the columns in Firefox.

Regards,
Jyoti Arora

 

Post a Comment

<< Home