on 12-12-2007 11:28 AM
Hello all,
I have a business requirement in which I have to display the data neatly on a table. The table is created dynamically as it is dependent on the R/3 output. The requirement is that if a value displayed in the table is negative, it has to be displayed in red. Is this possible using Web Dynpro?
Thanks in advance,
PKS.
Hi,
It is possible in Webdynpro. For the table columns you will be having A textview as table cell editor attached. If you just want the font color to appear in red you can do so by changing the Semantic color property of the Text view dynamically at runtime.
For this you need to have an attribute of type com.sap.ide.webdynpro.uielementdefinitions.TextViewSemanticColor.
Regards,
Nagarajan
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Sachin,
After creating the table do like this.
IWDTable table =(IWDTable) view.getElement("table_ID");
IWDTableColumn column= (IWDTableColumn)table.getGroupedColumn(1);
// assuming your cell Editor is TextView
IWDTextView columnText =(IWDTextView) column.getTableCellEditor();
// you can directly use this code just after creating
if(value<0)
columnText.setSemanticColor(WDTextViewSemanticColor.NEGATIVE);
regards,
Siva
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
84 | |
25 | |
12 | |
9 | |
7 | |
6 | |
5 | |
5 | |
4 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.