2006 Dec 15 4:26 PM
data: begin of t_object occurs 0,
num(20) type C,
end of t_object.
Data: t_ob like MARA-MATNR.
DATA: progname TYPE sy-repid,
dynnum TYPE sy-dynnr.
PARAMETERS: P_Objnum(20) Type C.
INITIALIZATION.
PROGNAME = SY-REPID.
DYNNUM = SY-DYNNR.
AT SELECTION-SCREEN ON VALUE-REQUEST FOR P_Objnum.
select MATNR into t_ob from MATNR where ERNAM = SY-UNAME.
t_object-num = t_ob.
append t_object.
endselect.
CALL FUNCTION 'F4IF_INT_TABLE_VALUE_REQUEST'
EXPORTING
retfield = 'ABC'
value_org = 'S'
dynpprog = PROGNAME
dynpnr = DYNNUM
TABLES
value_tab = t_OBJECT.
When I click on matchcode for parameter P_OBJNUM, I see a blank list. How do I modify my code ?
2006 Dec 15 4:36 PM
Hi Rajesh,
Can you add dynprofield as exporting paramter to the FM as below:
call function 'F4IF_INT_TABLE_VALUE_REQUEST'
exporting
retfield = 'ABC'
dynprofield = 'P_OBJNUM'
dynpprog = PROGNAME
dynpnr = DYNNUM
value_org = 'S'
tables
value_tab = T_OBJECT.
Also check if t_object internal table has values after the select statement by debugging through.
Cheers,
Vikram
Pls reward for helpful replies!!
Hi Rajesh,
Can you add dynprofield as exporting paramter to the FM as below:
call function 'F4IF_INT_TABLE_VALUE_REQUEST'
exporting
retfield = 'ABC'
dynprofield = 'P_OBJNUM'
dynpprog = PROGNAME
dynpnr = DYNNUM
value_org = 'S'
tables
value_tab = T_OBJECT.
Also check if t_object internal table has values after the select statement by debugging through.
Cheers,
Vikram
Pls reward for helpful replies!!
2006 Dec 15 4:36 PM
Hi Rajesh,
Can you add dynprofield as exporting paramter to the FM as below:
call function 'F4IF_INT_TABLE_VALUE_REQUEST'
exporting
retfield = 'ABC'
dynprofield = 'P_OBJNUM'
dynpprog = PROGNAME
dynpnr = DYNNUM
value_org = 'S'
tables
value_tab = T_OBJECT.
Also check if t_object internal table has values after the select statement by debugging through.
Cheers,
Vikram
Pls reward for helpful replies!!
2006 Dec 15 4:38 PM
On the top of list I see "Restrict valuye range (3) 115 Entries found". But it does not get dispalyed in the list ......
2006 Dec 15 4:39 PM
Modify ur code....
select MATNR into t_ob from <b>MARA</b> where ERNAM = SY-UNAME.
t_object-num = t_ob.
append t_object.
endselect.
Message was edited by:
Ramesh Babu Chirumamilla
2006 Dec 15 4:42 PM
Yes I did, I see the 115 entries found at the top but I do not see the entries displayed in list.....
2006 Dec 15 5:01 PM
Rajesh,
declare like this.
data: begin of t_object occurs 0,
<b>matnr like mara-matnr,</b>
end of t_object.
Data: t_ob like MARA-MATNR.
DATA it_return LIKE ddshretval OCCURS 0 WITH HEADER LINE.
PARAMETERS: P_Objnum(20) Type C.
INITIALIZATION.
PROGNAME = SY-REPID.
DYNNUM = SY-DYNNR.
select matnr into table t_object from mara.
sort t_object by matnr.
clear t_object.
CALL FUNCTION 'F4IF_INT_TABLE_VALUE_REQUEST'
EXPORTING
<b> retfield = 'MARA'
window_title = 'TEST'</b>
value_org = 'S'
dynpprog = PROGNAME
dynpnr = DYNNUM
TABLES
value_tab = t_OBJECT
return_tab = it_return
EXCEPTIONS
parameter_error = 1
no_values_found = 2
OTHERS = 3.
IF sy-subrc = 0.
endif.
Vivek
2006 Dec 15 5:04 PM
Here is the complete code:
data: begin of t_object occurs 0,
*num(20) type C,
matnr like mara-matnr,
end of t_object.
Data: t_ob like MARA-MATNR.
DATA it_return LIKE ddshretval OCCURS 0 WITH HEADER LINE.
PARAMETERS: P_Objnum(20) type c.
INITIALIZATION.
AT SELECTION-SCREEN ON VALUE-REQUEST FOR P_Objnum.
select matnr into table t_object from mara.
sort t_object by matnr.
clear t_object.
CALL FUNCTION 'F4IF_INT_TABLE_VALUE_REQUEST'
EXPORTING
retfield = 'MARA'
window_title = 'TEST'
value_org = 'S'
TABLES
value_tab = t_OBJECT
return_tab = it_return
EXCEPTIONS
parameter_error = 1
no_values_found = 2
OTHERS = 3.
IF sy-subrc = 0.
CLEAR t_object.
READ TABLE it_return INDEX 1.
p_objnum = it_return-fieldval.
endif.
Reward points if helpful.
Vivek
| User | Count |
|---|---|
| 6 | |
| 2 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 |