cancel
Showing results for 
Search instead for 
Did you mean: 

how to display itab values in text boxes?

former_member182426
Active Contributor
0 Kudos

hi friends,

i am filling ITAB with some fields, now i have to get one by one field and i have to display this field values in textboxes in BSP layout page.

for exaple my ITAB contains 2 fields,

ID, NAME.

In layout there are two Input boxes.

now i have to display ITAB fields ID and NAME fields in layout inputboxes.

plz Any helps with some example code.......

Regards,

Shankar.

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

Hi shankar,

Let me know whether ur issue is solved or not

Regards,

Sri

Answers (3)

Answers (3)

former_member188685
Active Contributor
0 Kudos

you can use Dropdownlistbox in this case it will be simple to show the table values in the list box.

check the sample application

SBSPEXT_HTMLB

page DropdownListBox.bsp

Former Member
0 Kudos

In layout

for input fields set the value property

value = "<%= i_id %>" for id field

value = "<%= i_name %>" for name field

Former Member
0 Kudos

hi shankar,

try this code Oninputprocessing event,

DATA: event type ref to cl_htmlb_event,
event = cl_htmlb_manager=>get_event( runtime->server->request ).
if event->id = 'btn'.

wa-id = '123'.
wa-name = 'abcd'.
append wa to itab.

if itab is not initial.
loop at itab into wa.
i_id = wa-id.
i_name = wa-name.
endloop.
endif.
endif.

Page attributes

i_id type string
i_name type string

Regards,

sri