I may not be able to do what I'm trying to accomplish...but here's the issue:
I started a new AppStyle by utilizing the "Nautilus.isl" as the beginning template. I like the look and feel overall and "tweaked" it ever so slightly until I got the desired results. One feature I'd like to have on my Grid is an alternating row color...which when adding a grid without styling is easier using the override on the RowAlternateAppearance property. But AppStyle appears to be an image - in my opinion - that circumvents code I've added to set the alternate color on a grid's band.
Now...if I start with a blank Style Library - with or without themes - it works great. I can set the Alternate Item properties and see the results in the AppStyle designer. However, if I start with a template to use as my base - the best I can achieve is an outline on the row - which is why I assume an image is sitting on top of the cells. Here's an example with the Alternate Item Background color set to red - to standout - and the results:
Is there a way to get the background color I want to fill the cells across the row, or is starting with a template as my base design simply the wrong approach if I want to do this?
Thanks
Hi,
I took a look at the Nautilus style and I notice that the GridRow UIRole does indeed have an ImageBackground assigned to it. However, when I removed this, that doesn't seem to make any difference to the AlternateItem state on the row. It still doesn't show through.
It looks to me like the row color is not visible because the cells are covering it. This is why you see a border around the row - that's the only part of the row not covered by a cell.
Sure enough, the Base role in this style library has it's background color set to White. This gives every cell a solid white BackColor which covers the row color.
So one easy way to get around this is to go to the GridCell UIRole and, on the Background chunk, set the Alpha to Transparent. Or, you could set the Background color to Transparent. The latter might be better, actually, since that way you could still override it if you want to color an individual cell in your application.
First of all...Thanks Mike. I appreciate you taking a look at this.
I still can't get it to work...even with the GridCell UIRole changes. Whatever is blocking the cell row color still overrides any of my settings. There are so many properties to consider within these controls that it takes a lot of work to drill down and find what you need sometimes. At this point I've wasted way too much time on something as stupid as the "alternate row color" that could be put to use on something else - know what I mean? - so I've moved on. I changed my starting library to the VS2008 template and the alternate color works great.
Sometimes development is all about compromise and keeping focus on the end goal...and while I prefer the Nautilus style, there's a work around with VS2008 that allows greater control of the grid both in the AppStyle designer and in code - so it's all good.
Thanks again!
I can certainly understand that.If you don't want to spend any more time pursuing this, then that is, of course, up to you.
I took another look and it looks like I was wrong - or rather, I was right about the base role, but that's not quite complete. In addition to making the cells transparent, there is also an Image background applied to the rows. So you have to get rid of both.
In case you want to try again, here's exactly what I did:
Hi Mike,
I am using the Nautilus style for the grid in asp.net page and running into a similar issue. All i want is to
have the grid lines visible for all the rows and columns. Even though, i have turned it on, by default the grid lines
do not show up for the alternate rows. Could you please help me with this issue. It looks like similar to
the issue being addressed in this post. I tired to follow the steps you gave but kind of got lost while doing it.
Also what is not clear is how do app style these changes make it to the website.
Thanks!!!
I'm afraid I don't know anything about ASP.Net. This forum is for WinForms. You should post your question in the appropriate forum in the ASP.Net forums.