08-29-2007 12:43 PM
I need to know what type will be the tables and any other important things.
I have never used it before.
An example would help me.
Thanks.
08-29-2007 12:45 PM
Hi,
seee this..
SFIELDS-TABNAME = 'KONPD'.
SFIELDS-FIELDNAME = 'BZWRT'.
SFIELDS-COMP_TAB = 'KONA'.
SFIELDS-COMP_FIELD = 'WAERS'.
SFIELDS-FIELD_ATTR = '01'.
SFIELDS-FIELD_OBL = 'X'.
APPEND SFIELDS TO XFIELDS.
CLEAR SFIELDS.
SFIELDS-TABNAME = 'KONA'.
SFIELDS-FIELDNAME = 'WAERS'.
SFIELDS-VALUE = 'USD'.
SFIELDS-FIELD_ATTR = '02'.
APPEND SFIELDS TO XFIELDS.
CALL FUNCTION 'POPUP_GET_VALUES'
EXPORTING
POPUP_TITLE = TEXT-001
START_COLUMN = '5'
START_ROW = '5'
IMPORTING
RETURNCODE = SRETURN
TABLES
FIELDS = XFIELDS.
IF SRETURN NE 'A'.
Read input value
LOOP AT XFIELDS INTO SFIELDS WHERE FIELDNAME = 'BZWRT'.
WRITE SFIELDS-VALUE+117(15) TO ZBZWRT.
ENDLOOP.
endif.
rwards if useful,
regards,
nazeer
08-29-2007 12:45 PM
Hi,
Goto Se37->Open the Function module.
<b>And click on the button "Function module documentation".
Or use Goto->Documentation menu option.</b>
Let us know if you cant see the documentation.
Regards,
Sesh
08-29-2007 12:55 PM
hi,
you have to pass the following:
NO_VALUE_CHECK --> leave blank
POPUP_TITLE--> Pass popup title
START_COLUMN--> leave blank
START_ROW--> leave blank
In table FIELDS;
TABNAME --> pass the table from which your field is comming
FIELDNAME --> pass your field name here directly
Leave everything else blank!
Regards.
08-29-2007 12:56 PM
08-29-2007 1:11 PM
Hi,
use the following sample code:
data: wa_fields like SVAL,
li_fields TYPE STANDARD TABLE OF SVAL.
move 'KONA' to wa_fields-TABNAME.
move 'KNUMA' to wa_fields-FIELDNAME.
append wa_fields to li_fields.
move 'BSEG' to wa_fields-TABNAME.
move 'BUKRS' to wa_fields-FIELDNAME.
append wa_fields to li_fields. " add more fields if required
CALL FUNCTION 'POPUP_GET_VALUES'
EXPORTING
NO_VALUE_CHECK = ' '
popup_title = 'Test title'
START_COLUMN = '5'
START_ROW = '5'
IMPORTING
RETURNCODE =
tables
fields = li_fields
EXCEPTIONS
ERROR_IN_FIELDS = 1
OTHERS = 2
.
IF sy-subrc <> 0.
loop at li_fields into wa_fields.
" use values of field VALUE
ENDLOOP.
ENDIF.
Regards.
08-29-2007 12:51 PM
Hi,
this function module is used to give the values of a table or from different table
as popup
data: itab like mara occurs 0 with header line.
select * from mara into table itab up to 1 rows.
data: begin of table occurs 0.
include structure SVAL.
data: end of table.
loop at ITAB.
TABLE-TABNAME = 'MARA'.
TABLE-FIELDNAME = 'MATNR'.
TABLE-VALUE = ITAB-MATNR.
APPEND TABLE.
endloop.
CALL FUNCTION 'POPUP_GET_VALUES'
EXPORTING
NO_VALUE_CHECK = ' '
popup_title = 'HALO'
START_COLUMN = '5'
START_ROW = '5'
IMPORTING
RETURNCODE =
tables
fields = TABLE
EXCEPTIONS
ERROR_IN_FIELDS = 1
OTHERS = 2
.
IF sy-subrc <> 0.
MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
ENDIF.
thanks & regards,
Venkatesh