cancel
Showing results for 
Search instead for 
Did you mean: 

Change table cell color for input field

Former Member
0 Kudos

In my application, I have a table with 12 monthly columns. Depending on the data entered, I need to change individual cell colors for any specific monthly column in that row. The application is monthly sales by salesman, and I want to highlight the month that they made their yearly quota. If the cells were text views I could use the semantic color, but don't know how to do it for input fields. Help will be appreciated and rewarded.

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

Koen Labie, I have been through the documentation and can't figure out the solution.

Wenonah Jaques, your solution changes the color for the whole column (if the attribute points to an element in the table, the column gets the color of the first element). I need to be able to modify the cell color at the cell level, not the row or column.

Former Member
0 Kudos

Hi ,

Unfortunately, there is no property for the input field cell editor type which allows you to specify the colour. Hence, you will not be able to set the colour at the cell level if you use input fields.

Basically, if you want to change the properties of a cell editor (of a table), check if this is possible by having a look at the available properties of that UI element in the layout. If there is a property which you can bind to an attribute, then you can dynamically change the values of the property bu adding an attribute to the context node. However, if the property itself is not present, then there is nothing you can do about it.

Regards,

Wenonah

Answers (3)

Answers (3)

Former Member
0 Kudos

Hi,

I know this thread is answered but thought of giving a link which gives clear idea of how we can create coloring for particular cells in wendynpro table.

Please follow the linke below for cell coloring:

http://www.sdn.sap.com/irj/scn/go/portal/prtroot/docs/library/uuid/707fb792-c181-2d10-61bd-ce15d58b5...

Hope this helps if some one tries for this functionality as i did.

Thanks!

Former Member
0 Kudos

Hi,

Define a context node of cardinality 0...n. Define an attribute of this node of type WDUI_TABLE_CELL_DESIGN.

Map this attribute to the 'cell design' property of the table column. At runtime, change the value of this attribute. Check the domain WDUI_TABLE_CELL_DESIGN for the values.

Hope this helps.

Regards,

Wenonah

Former Member
0 Kudos

Hi,

If you check the webdynpro application wdr_test_table, you can find the result of this [documentation|http://help.sap.com/saphelp_nw2004s/helpdata/en/56/5e9041d3c72e7be10000000a1550b0/frameset.htm]

grtz,

Koen