2007 May 04 2:17 PM
Hi, All:
in the dialog programming. I define one table control, within it, I define one field as list box. how to populate all value to this list field within table control.
Thanks,
victor
If the domain has fixed values it will get updated automtically.
2007 May 04 2:22 PM
If the domain has fixed values it will get updated automtically.
2007 May 04 2:27 PM
Hi, Vineela Allamneni:
My list value comes from one database table.
Thanks,
Victor
2007 May 04 2:22 PM
Hi,
Check the DEMO program DEMO_DROPDOWN_LIST_BOX. Hope it will be useful for ur requirement.
Thanks,
Satya
2007 May 04 2:31 PM
Hello,
Use FN VRM_SET_VALUES.
I am providing the code below witten by Rich, please go through.
report zrich_0001.
type-pools: vrm.
data: begin of itab occurs 0,
field(10) type c,
end of itab.
data: ivrm_values type vrm_values.
data: xvrm_values like line of ivrm_values.
data: name type vrm_id.
start-of-selection.
call screen 100.
*&---------------------------------------------------------------------*
*& Module STATUS_0100 OUTPUT
*&---------------------------------------------------------------------*
* text
*----------------------------------------------------------------------*
module status_0100 output.
* SET PF-STATUS 'xxxxxxxx'.
* SET TITLEBAR 'xxx'.
name = 'ITAB-FIELD'.
xvrm_values-key = '1234567890'.
xvrm_values-text = '1234567890'.
append xvrm_values to ivrm_values.
xvrm_values-key = '0987654321'.
xvrm_values-text = '0987654321'.
append xvrm_values to ivrm_values.
call function 'VRM_SET_VALUES'
exporting
id = name
values = ivrm_values.
endmodule. " STATUS_0100 OUTPUT
*&---------------------------------------------------------------------*
*& Module USER_COMMAND_0100 INPUT
*&---------------------------------------------------------------------*
* text
*----------------------------------------------------------------------*
module user_command_0100 input.
endmodule. " USER_COMMAND_0100 INPUT
*&SPWIZARD: DECLARATION OF TABLECONTROL 'ITABCON' ITSELF
controls: itabcon type tableview using screen 0100.
*&SPWIZARD: OUTPUT MODULE FOR TC 'ITABCON'. DO NOT CHANGE THIS LINE!
*&SPWIZARD: UPDATE LINES FOR EQUIVALENT SCROLLBAR
module itabcon_change_tc_attr output.
describe table itab lines itabcon-lines.
| User | Count |
|---|---|
| 6 | |
| 3 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 |