on 08-23-2004 4:02 PM
Hi,
I am creating a tableview in which I would like to merge few cells for few of the rows (based on some condition). I am also trying to make use of Table Iterator for the same but not getting proper clue.
Can someone please help.
Thanks and regards,
Sachin K
There are about a millions sources here in this forum for that A quick search will provide several for you.
Here are some links you should check out...
And of course the basics...
<a href="/people/brian.mckellar/blog/2004/06/11/bsp-trouble-shooting-getting-help">BSP Trouble Shooting: Getting Help</a>
<a href="/people/brian.mckellar/blog/2003/10/31/bsp-programming-htmlb-tableview-iterator">BSP Programming: HTMLB TableView Iterator</a>
Here is a code sample of doing something in the <b>IF_HTMLB_TABLEVIEW_ITERATOR~GET_COLUMN_DEFINITIONS</b>
method IF_HTMLB_TABLEVIEW_ITERATOR~GET_COLUMN_DEFINITIONS .
FIELD-SYMBOLS: <def> LIKE LINE OF p_column_definitions.
APPEND INITIAL LINE TO p_column_definitions ASSIGNING <def>.
<def>-COLUMNNAME = 'SID'.
<def>-TITLE = 'System'.
<def>-WIDTH = '10%'.
<def>-SORT = 'X'.
APPEND INITIAL LINE TO p_column_definitions ASSIGNING <def>.
<def>-COLUMNNAME = 'STATUS'.
<def>-TITLE = 'Status'.
<def>-WIDTH = '10%'.
<def>-SORT = 'X'.
APPEND INITIAL LINE TO p_column_definitions ASSIGNING <def>.
<def>-COLUMNNAME = 'CREATIMEDA'.
<def>-TITLE = 'Date'.
<def>-WIDTH = '10%'.
APPEND INITIAL LINE TO p_column_definitions ASSIGNING <def>.
<def>-COLUMNNAME = 'CREATIMETI'.
<def>-TITLE = 'Time'.
<def>-WIDTH = '10%'.
APPEND INITIAL LINE TO p_column_definitions ASSIGNING <def>.
<def>-COLUMNNAME = 'ALERTMSG'.
<def>-TITLE = 'Text'.
<def>-WIDTH = '50%'.
<def>-WRAPPING = 'X'.
APPEND INITIAL LINE TO p_column_definitions ASSIGNING <def>.
<def>-COLUMNNAME = 'UNAME'.
<def>-TITLE = 'Assigned User'.
<def>-WIDTH = '10%'.
<def>-SORT = 'X'.
endmethod.
Follow that with the code from <i><b>IF_HTMLB_TABLEVIEW_ITERATOR~RENDER_ROW_START</b></i>
method IF_HTMLB_TABLEVIEW_ITERATOR~RENDER_ROW_START .
m_row_ref ?= p_row_data_ref.
endmethod.
and ending with this code from <i><b>IF_HTMLB_TABLEVIEW_ITERATOR~RENDER_CELL_START</b></i>
method IF_HTMLB_TABLEVIEW_ITERATOR~RENDER_CELL_START .
* Data Declarations
DATA: dataValue TYPE STRING,
tmp TYPE STRING,
tmptext TYPE STRING.
CASE p_column_key.
WHEN 'STATUS'.
dataValue = m_row_ref->STATUS.
case dataValue.
when ''.
tmp = '@5B@'.
tmptext = m_row_ref->STATUST.
when 'C'.
tmp = '@5B@'.
tmptext = m_row_ref->STATUST.
when 'D'.
tmp = '@5D@'.
tmptext = m_row_ref->STATUST.
when 'E'.
tmp = '@5C@'.
tmptext = m_row_ref->STATUST.
endcase.
DATA: image TYPE REF TO CL_HTMLB_IMAGE.
p_replacement_bee = cl_htmlb_image=>factory( id = 'img'
src = tmp
alt = tmptext ).
ENDCASE.
endmethod.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
98 | |
11 | |
11 | |
10 | |
10 | |
8 | |
6 | |
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.