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

Putting colour into TableView cells?

Hi there,

I've developed iViews in Java that put colour into a TableView's cells with code similar to the following:

<hbj:tableView id="da190Table"









visibleFirstRow="<%=myDA190Bean.getVisibleRow() %>"


visibleRowCount = "5"





//loop through table.....





I've gone to "CL_HTMLB_TABLEVIEW" in the class builder and am trying to find a method similar to "setStyleForCell()" seen in the above code. I'm also trying to find a class or interface similar to "TableCellStyle" so that I can get the colours easily. I hope I'm thinking the right way and that ABAP isn't too different to the way Java handles it on the Portal.

So if anyone can let me know how to get colour into TableView cells using BSP's I'll be really stoked...

Thanks for the help


Add a comment
10|10000 characters needed characters exceeded

Related questions

1 Answer

  • Posted on Dec 08, 2003 at 10:27 AM

    I am fairly new to the Web World and to BSP's, so I hope I am not leading you wrong. Here is what I have done so far to acomplish the same thing. I have used an HTMLB TableView Iterator and implemented the RENDER_CELL_START method. This lets you set styles, classes, and even replacement expressions. Brian McKellar has some very helpful WebLogs on Both TableView Iterators and BEEs that got me started down this path.

    Add a comment
    10|10000 characters needed characters exceeded

    • Yes, this is (unfortunately) the only way to go. We do not build a control tree in BSP during rendering. The controls are rendered on the fly. Which means that there are settings that you can only make while rendering. See weblogs on iterators. See also BSP app sbspext_htmlb or bsp_tableview.

      For design2002, you can set colors directly via p_style parameter. This was in the days before we got new limited list of colors, etc. For design2003, you can do something such as: p_style = 'celldesign:positive'.


      PS: I think I wrote something more about this in a previous append.

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.