Skip to Content
author's profile photo Former Member
Former Member

JSP tag syntax : TableView.setStyleForCell

According to the PDK6 documentation you can specify the background colour of an individual cell/row with the following, however it produces only an error.



(int rowIndex, int colIndex



<hbj:tableView id="SearchListTable"

model= "MyJCoBean.searchListModel"

design = "ALTERNATING"

headerVisible = "TRUE"

footerVisible = "TRUE"

fillUpEmptyRows = "TRUE"

selectionMode = "SINGLESELECT"

navigationMode = "BYPAGE"

visibleRowCount = "15"

width = "795"

headerText = "Partner Search Results"

visibleFirstRow = "<%=MyJCoBean.getVisibleFirstRow() %>"


<% SearchListTable.selectRow(MyJCoBean.getSelectedRow(),false);


SearchListTable.setStyleForCell(2, 2 TableCellStyle.NEGATIVE) ;



Error Message:

Caused by: com.sapportals.portal.prt.component.PortalComponentException: PortalComponentException

Component : null

Component class : null

Caused by: com.sapportals.portal.prt.servlets_jsp.server.compiler.CompilingException: C:/usr/sap/EPSB/j2ee/j2ee_00/cluster/server/services/servlet_jsp/work/jspTemp/irj/root/WEB-INF/portal/portalapps/com.sappi.crm.customerinfo9/work/pagelet/ ')' expected SearchListTable.setStyleForCell(2, 2

TableCellStyle.NEGATIVE) ;


C:/usr/sap/EPSB/j2ee/j2ee_00/cluster/server/services/servlet_jsp/work/jspTemp/irj/root/WEB-INF/portal/portalapps/com.sappi.crm.customerinfo9/work/pagelet/ setStyleForCell(int,int,com.sapportals.htmlb.enum.TableCellStyle) in com.sapportals.htmlb.table.TableView cannot be applied to (int,int)

SearchListTable.setStyleForCell(2, 2

TableCellStyle.NEGATIVE) ;

2 errors

Comments appreciated.



Add a comment
10|10000 characters needed characters exceeded

Related questions

1 Answer

  • author's profile photo Former Member
    Former Member
    Posted on May 24, 2004 at 02:11 PM

    You are missing a comma

    SearchListTable.setStyleForCell(2, 2 TableCellStyle.NEGATIVE) ;

    Should be

    SearchListTable.setStyleForCell(2, 2,TableCellStyle.NEGATIVE) ;

    Add a comment
    10|10000 characters needed characters exceeded

Before answering

You should only submit an answer when you are proposing a solution to the poster's problem. If you want the poster to clarify the question or provide more information, please leave a comment instead, requesting additional details. When answering, please include specifics, such as step-by-step instructions, context for the solution, and links to useful resources. Also, please make sure that you answer complies with our Rules of Engagement.
You must be Logged in to submit an answer.

Up to 10 attachments (including images) can be used with a maximum of 1.0 MB each and 10.5 MB total.