Skip to Content
0
3 days ago

BDC Not able to press ok button.

65 Views

hi,
Need suggestion, facing one issue. Tried some possible ways But still facing issue.

Need to call C223 Tcode.

I have one custom, report here i have material and plant displaying in the Matrix.
with respect to the line once click on the custom button at the application tool bar. Need to pass selected line material and plant.
First i tried Call transaction.

SET PARAMETER ID 'WRK' FIELD %%g00-mapl-werks.

SET PARAMETER ID 'MAT' FIELD %%g00-mapl-matnr.

CALL TRANSACTION 'C223'. "AND SKIP FIRST SCREEN.

I can call the transaction, but don't know Material no i am not able to pass. then decided to use BDC.

DATA: bdcdata LIKE bdcdata OCCURS 0 WITH HEADER LINE,

messtab LIKE bdcmsgcoll OCCURS 0 WITH HEADER LINE,

lv_mode TYPE c VALUE 'A'.

REFRESH bdcdata.

CLEAR bdcdata.

CLEAR bdcdata.

bdcdata-program = 'SAPLCMFV'.

bdcdata-dynpro = '1000'.

bdcdata-dynbegin = 'X'.

APPEND bdcdata.

* CLEAR bdcdata.

* bdcdata-fnam = 'BDC_OKCODE'.

* bdcdata-fval = '=REFR'.

* APPEND bdcdata.

CLEAR bdcdata.

bdcdata-fnam = 'BDC_SUBSCR'.

bdcdata-fval = 'SAPLCMFV'.

APPEND bdcdata.

CLEAR bdcdata.

bdcdata-fnam = 'BDC_CURSOR'.

bdcdata-fval = 'MKAL-MATNR'.

APPEND bdcdata.

CLEAR bdcdata.

bdcdata-fnam = 'MKAL-WERKS'.

bdcdata-fval = %%g00-mapl-werks.

APPEND bdcdata.

CLEAR bdcdata.

bdcdata-fnam = 'MKAL-MATNR'.

bdcdata-fval = %%g00-mapl-matnr.

APPEND bdcdata.

CLEAR bdcdata.

bdcdata-fnam = 'BDC_SUBSCR'.

bdcdata-fval = 'SAPLCMFV'.

APPEND bdcdata.

CLEAR bdcdata.

bdcdata-fnam = 'BDC_OKCODE'.

bdcdata-fval = '/00'.

APPEND bdcdata.

CALL TRANSACTION 'C223'

USING bdcdata

MODE lv_mode MESSAGES INTO messtab.

Still pop up message is coming. once if i press ok then data will show. i need to press enter

i tried. =/Enter too.. nothing worked.

I need to call Foreground only 'A", User want to see the data... no need of background.

c223okcode.png

Attachments

c223okcode.png (38.3 kB)