2007 Sep 05 3:07 PM
Hi,
I want to find Header BOM materials corresponding to component on multi-level basis.
This can be acheived by CS15.
How can i fetch the data which is displayed in CS15 in my Program.
Is there any function module available for this?
Thanks,
Vaibhav
2007 Sep 05 3:14 PM
Hi Vaibhav,
Check the following func modules:
CS_WHERE_USED_MAT
CS_WHERE_USED_MAT_VIA_CLA
CS_WHERE_USED_MAT_ANY
For more details you can check the following prog:
RCS15001
Reward points if helpful answer.
Asvhender
2007 Sep 05 3:14 PM
Hi Vaibhav,
Check the following func modules:
CS_WHERE_USED_MAT
CS_WHERE_USED_MAT_VIA_CLA
CS_WHERE_USED_MAT_ANY
For more details you can check the following prog:
RCS15001
Reward points if helpful answer.
Asvhender
2007 Sep 05 3:45 PM
I had done this - here is the code -
REFRESH T_WULTB.
CLEAR T_WULTB.
CALL FUNCTION 'CS_WHERE_USED_MAT'
EXPORTING
DATUB = P_DATUB
DATUV = P_DATUV
MATNR = T_STBA-IDNRK
WERKS = T_STBA-WERKS
TABLES
WULTB = T_WULTB
EQUICAT = T_EQUICAT
KNDCAT = T_KNDCAT
MATCAT = T_MATCAT
STDCAT = T_STDCAT
TPLCAT = T_TPLCAT
PRJCAT = T_PRJCAT
EXCEPTIONS
CALL_INVALID = 1
MATERIAL_NOT_FOUND = 2
NO_WHERE_USED_REC_FOUND = 3
NO_WHERE_USED_REC_SELECTED = 4
NO_WHERE_USED_REC_VALID = 5
OTHERS = 6
.
IF SY-SUBRC <> 0.
* MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
* WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
EXIT.
ENDIF.
Hope it helps.
2007 Sep 11 6:46 PM