Your Privacy Matters: We use our own and third-party cookies to improve your experience on our website. By continuing to use the website we understand that you accept their use. Cookie Policy
1960
HeaderStyleDefault.CssClass not working when TemplatedColumn is present.
posted

Hello,

First of all, I'm attaching a VS2008 project to reproduce the issue.

I want my grid to get the styles from a css. In order to do that I created my classes "GridRow" and "GridHeader". Then I set the RowStyleDefault.CssClass and HeaderStyleDefault.CssClass to the corresponding classes.

Test number one: Add one templated column and one normal column (those columns are already present on the attached project). When the page runs the header does not use the GridHeader class. It inherits the properties from GridRow instead. That's wrong.

Test number two: Now remove the templated column, run the page again. This time the header is only using the GridHeader class. That's the behavior I'm expecting.

Test number three: Add the templated column again, remove the RowStyleDefault.CssClass property, set RowStyleDefault.BackColor = White. Run the page, the header is using the the GridHeader class, which is the correct behavior.

It looks like the presence of the templated column affects the assignment of css classes.

Has anyone else noticed this problem?

HeaderStylesheetIssue.zip
Parents Reply Children
No Data