on 12-10-2007 1:49 PM
experts,
I rendered checkbox and input fields in table view and data is storing well into the tables.
when display the same data the check boxes are not checked which have value 'X'. and also the text in input field also not visible.
help me in this regard.
Thanks
vijay
Post your code here including Iterator code if u r using.
Raja T
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Raja,
<u><b>TableView</b></u>
<htmlb:tableView id = "TV"
table = "<%= controller->int_table %>"
design = "ALTERNATING"
onRowSelection = "MyEventRowSelection"
selectionMode = "MULTILINEEDIT"
filter = "SERVER"
visibleRowCount = "12"
columnWrapping = "TRUE"
iterator = "<%= controller %>"
<b><u>Iterator Coding</u></b>
<b><u>get_column_definitions</u></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 = 'VENDOR'.
<def>-title = 'Vendor'.
<def>-edit = ''.
<def>-horizontalalignment = 'left'.
<def>-width = '240'.
append initial line to p_column_definitions assigning <def>.
<def>-columnname = 'VENDORID'.
<def>-title = 'ID'.
<def>-edit = ''.
<def>-horizontalalignment = 'left'.
<def>-width = '90'.
append initial line to p_column_definitions assigning <def>.
<def>-columnname = 'CONTRACT'.
<def>-title = 'Contract'.
<def>-edit = ''.
<def>-horizontalalignment = 'left'.
<def>-width = '90'.
append initial line to p_column_definitions assigning <def>.
<def>-columnname = 'STATUS'.
<def>-title = 'Status'.
<def>-edit = 'X'.
<def>-horizontalalignment = 'left'.
<def>-width = '60'.
append initial line to p_column_definitions assigning <def>.
<def>-columnname = 'REF_CODE'.
<def>-title = 'Reference Code'.
<def>-edit = 'X'.
<def>-horizontalalignment = 'left'.
<def>-width = '120'.
append initial line to p_column_definitions assigning <def>.
<def>-columnname = 'INCLUDE_EXCLUDE'.
<def>-title = 'Include/Exclude'.
<def>-edit = 'X'.
<def>-horizontalalignment = 'left'.
<def>-width = '100'.
append initial line to p_column_definitions assigning <def>.
<def>-columnname = 'JUSTIFICATION'.
<def>-title = 'Justification'.
<def>-edit = 'X'.
<def>-horizontalalignment = 'left'.
<def>-width = '240'.
m_row_ref type ref to int_table.(class attribute)
<b><u>render_row_start</u></b>
method if_htmlb_tableview_iterator~render_row_start.
m_row_ref ?= p_row_data_ref.
endmethod.
<u><b>render_cell_start.</b></u>
method if_htmlb_tableview_iterator~render_cell_start.
data: just type string.
case p_column_key.
when 'INCLUDE_EXCLUDE'.
if p_edit_mode is not initial.
p_replacement_bee = cl_htmlb_checkbox=>factory(
id = p_cell_id ).
endif.
when 'JUSTIFICATION'.
just = m_row_ref->justification.
p_replacement_bee = cl_htmlb_inputfield=>factory( id = p_cell_id
type = 'STRING'
size = '60' ).
endcase.
Thanks
Vijay
Vijaykumar,
You need to pass the values to checkbox & Inputfield:
For example:
date = m_row_ref->SDATE.
p_replacement_bee = CL_HTMLB_INPUTFIELD=>FACTORY(
id = p_cell_id
value = date
type = 'DATE'
showHelp = 'TRUE'
cellValue = 'TRUE' ).
same way for Checkbox too:
p_replacement_bee = CL_HTMLB_CHECKBOX=>FACTORY
( id = p_cell_id
checked = m_row_ref->ACTV_FLAG ).
Modify your code based the fieldname.
Raja T
User | Count |
---|---|
95 | |
11 | |
10 | |
9 | |
9 | |
7 | |
6 | |
5 | |
5 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.