2012 Sep 15 5:06 AM
Hi ,
I Cant able to Pass value from my zreport to Tcode "co40 " , Except "PLNUM FIELD"
In co40 Tcode its having 3 Parameters
This is the Code that i had done to pass value from my Zreport to CO40 Unfortunately
Unable to Pass parameter ID 'ANR ' (PLNUM)
SET PARAMETER ID : 'ANR' FIELD selfield-VALUE,
'PAF' FIELD ZAUFNR,
'AAF' FIELD 'PP02',
'TPA' FIELD 'X' .
Please Help me To Sort out this Issue...... ASAP
Thanks in Advance .
Prakash .S
2012 Sep 15 9:57 AM
Hi Prkash,
I think that there is an issue here, in which they missed this field, nontheless,
here is a solution ready to cut and paste with the values you provided:
REPORT zprg39.
DATA: BEGIN OF bdctab OCCURS 100.
INCLUDE STRUCTURE bdcdata.
DATA: END OF bdctab.
PERFORM bdc_screen USING 'SAPLCOKO1' '0150' 'X'.
PERFORM bdc_fill USING 'AFPOD-PLNUM' 'P140N'.
PERFORM bdc_fill USING 'AFPOD-TPAUF' 'X'.
PERFORM bdc_fill USING 'AUFPAR-PP_AUFART' 'PP02'.
PERFORM bdc_fill USING 'CAUFVD-AUFNR' '13'.
call transaction 'CO40' USING BDCTAB.
*------------------------------------------------------------
* form Start new screen
*------------------------------------------------------------
FORM bdc_screen USING program dynpro dynbegin .
CLEAR bdctab.
bdctab-program = program.
bdctab-dynpro = dynpro.
bdctab-dynbegin = dynbegin .
APPEND bdctab.
ENDFORM. "bdc_screen
*------------------------------------------------------------
* form Fill BDCTAB.
*------------------------------------------------------------
FORM bdc_fill USING fnam fval.
CLEAR bdctab.
bdctab-fnam = fnam.
bdctab-fval = fval.
APPEND bdctab.
ENDFORM. "bdc_fill
2012 Sep 15 6:28 AM
post ur entire code, i doubt that at the time of passing these fields may be empty.
2012 Sep 15 7:34 AM
ZAUFNR = 'P0492m'.
SET PARAMETER ID : 'ANR' FIELD selfield-VALUE,
'PAF' FIELD ZAUFNR,
'AAF' FIELD 'PP02',
'TPA' FIELD 'X' .
This is the Value I Had Passed at Runtime .
2012 Sep 15 7:42 AM
check the values for the other fields also.
what are the statements just after passing values to parameter id.
and i have asked u to post ur entire code of the report.
2012 Sep 15 8:03 AM
hi abishek,
Please find the Src ,
*&---------------------------------------------------------------------*
*& Report ZPRG39 *
*& *
*&---------------------------------------------------------------------*
*& *
*& *
*&---------------------------------------------------------------------*
report zprg39 .
set parameter id : 'ANR' field 'PLNUM',
'PAF' field 'P140N' ,
'AAF' field 'PP02',
'TPA' field 'X' .
call transaction 'CO40'." AND SKIP FIRST SCREEN.
2012 Sep 15 9:57 AM
Hi Prkash,
I think that there is an issue here, in which they missed this field, nontheless,
here is a solution ready to cut and paste with the values you provided:
REPORT zprg39.
DATA: BEGIN OF bdctab OCCURS 100.
INCLUDE STRUCTURE bdcdata.
DATA: END OF bdctab.
PERFORM bdc_screen USING 'SAPLCOKO1' '0150' 'X'.
PERFORM bdc_fill USING 'AFPOD-PLNUM' 'P140N'.
PERFORM bdc_fill USING 'AFPOD-TPAUF' 'X'.
PERFORM bdc_fill USING 'AUFPAR-PP_AUFART' 'PP02'.
PERFORM bdc_fill USING 'CAUFVD-AUFNR' '13'.
call transaction 'CO40' USING BDCTAB.
*------------------------------------------------------------
* form Start new screen
*------------------------------------------------------------
FORM bdc_screen USING program dynpro dynbegin .
CLEAR bdctab.
bdctab-program = program.
bdctab-dynpro = dynpro.
bdctab-dynbegin = dynbegin .
APPEND bdctab.
ENDFORM. "bdc_screen
*------------------------------------------------------------
* form Fill BDCTAB.
*------------------------------------------------------------
FORM bdc_fill USING fnam fval.
CLEAR bdctab.
bdctab-fnam = fnam.
bdctab-fval = fval.
APPEND bdctab.
ENDFORM. "bdc_fill
2012 Sep 15 10:48 AM
I m Not looking for bdc , please Help me to pass value Through Parameter ID ......
2012 Sep 15 12:25 PM
I guess you have got the Parameter IDs jumbled.
Planned Order : Field name = PLNUM , Parameter ID = PAF
Order type : Field name = AUFART , Parameter ID = AAF
Order Number : Field name = AUFNR , Parameter ID = ANR .
Partial Conv : Parameter ID = TPA
2012 Sep 15 12:16 PM
2012 Sep 15 1:36 PM
Hi,
As I said before there is a sap issue there that requires a SAP note or maybe an OSS.
If you wanna manually fix this the place, in my mind, would be in include LCOKO1O1X
in MODULE DATA_SHOW OUTPUT, using some thing like:
IF SY-TCODE EQ 'CO40'.
GET PARAMETER ID 'ANR' FIELD CAUFVD-AUFNR.
ENDIF.
Best,
Iftah