Page 1 of 1

text area background color not the same as row

Posted: Wed Dec 21, 2016 11:50 am
by ppbedz
I have a grid consisting of several columns. The grid properties are set to have the odd and even rows display in different colors. One of the columns in my grid contains a text area. The text area does not display with the same color as the row. The text area background is always white regardless of the row. I have tried to bind a field to the background color of the text area to control the color. This works fine unless the user sorts, filters, etc. The value in the rowcolor background property does not seem to move with the row.

Example:

In this example I set the row background color of the text area to gray or blue (odd/even rows).

Row 1 = grey background, text area grey
Row 2 = blue background, text area blue
Row 3 = grey background, text area grey

A filter is requested that causes Row 2 to be the only row displayed. My text area background is now displayed as grey instead of blue. The rest of the row has a blue background.

How do I ensure that the text area background retains the same color as the rest of the row when the grid is filtered, sorted, etc?

Thank you,
Patti

Re: text area background color not the same as row

Posted: Wed Dec 21, 2016 4:44 pm
by matt.denninghoff
In Visual Designer, find the "background color" property of the TextArea that is inside your grid. Set the property to: inherit

That should solve your problem without needing to bind or do anything complicated.

Here's an explanation of "inherit": http://www.w3schools.com/cssref/css_inherit.asp

Re: text area background color not the same as row

Posted: Wed Dec 21, 2016 5:14 pm
by ppbedz
Thanks Matt, but I am not doing something right. Enclosed is a screen shot of the background color property and the resulting screen.

Patti

Re: text area background color not the same as row

Posted: Wed Dec 21, 2016 6:34 pm
by matt.denninghoff
Patti,
Sorry I didn't explain it more clearly: "background color" should not be "property: inherit;". It should just be "inherit" (without the quotes).

Re: text area background color not the same as row

Posted: Thu Dec 22, 2016 8:40 am
by ppbedz
Matt,

It still does not work for me. I have tried inherit; and inherit

The result is the same as the attachment I send previously. The inherit is on the background property for the text area. The text area is a field in the grid. Is that correct?

Patti

Re: text area background color not the same as row

Posted: Thu Dec 22, 2016 9:22 am
by ppbedz
Matt,

I found something on the internet about changing the property to "transparent" and it solved my problem.

Thanks for your help and Happy Holidays! Patti

Re: text area background color not the same as row

Posted: Thu Dec 22, 2016 4:22 pm
by matt.denninghoff
Patti,
I'm glad you found a solution. I only tested inherit on Firefox, so maybe the suggestion does not work in all browsers. Happy Holidays to you as well!

Re: text area background color not the same as row

Posted: Thu Sep 07, 2017 1:57 pm
by DanD
I realize that you had already found a solution, but what I have found to work is setting the background color of the text area to transparent. This works especially well in subfile grids.