BDC录屏TCODE:SHDB
我做的是固定资产过账这块,TCODE-F-90。
录屏的过程千万不能出错,有警告没关系。
录完凭,生成源代码,在这个基础上修改。
report ZASSET
no standard page heading line-size 255.
include bdcrecx1.
parameters: dataset(132) lower case.
data: begin of record,
* data element: BLDAT
BLDAT_001(010),
* data element: BLART
BLART_002(002),
* data element: BUKRS
BUKRS_003(004),
* data element: BUDAT
BUDAT_004(010),
* data element: MONAT
MONAT_005(002),
* data element: WAERS
WAERS_006(005),
* data element: SAEOBJART
DOCID_007(010),
* data element: NEWBS
NEWBS_008(002),
* data element: NEWKO
NEWKO_009(017),
* data element: WRBTR
WRBTR_010(016),
* data element: DZFBDT
ZFBDT_011(010),
* data element: NEWBS
NEWBS_012(002),
* data element: NEWKO
NEWKO_013(017),
* data element: BWASL
NEWBW_014(003),
* data element: WRBTR
WRBTR_015(016),
* data element: BZDAT
BZDAT_016(010),
* data element: FMORE
FMORE_017(001),
* data element: WRBTR
WRBTR_018(016),
* data element: BZDAT
BZDAT_019(010),
* data element: FMORE
FMORE_020(001),
end of record.
*** End generated data section ***
start-of-selection.
perform open_group.
perform bdc_dynpro using 'SAPMF05A' '0100'.
perform bdc_field using 'BDC_CURSOR'
'RF05A-NEWKO'.
perform bdc_field using 'BDC_OKCODE'
'/00'.
perform bdc_field using 'BKPF-BLDAT'
'2012-12-10'.
perform bdc_field using 'BKPF-BLART'
'KR'.
perform bdc_field using 'BKPF-BUKRS'
'1000'.
perform bdc_field using 'BKPF-BUDAT'
'2012-12-10'.
perform bdc_field using 'BKPF-MONAT'
'12'.
perform bdc_field using 'BKPF-WAERS'
'EUR'.
perform bdc_field using 'FS006-DOCID'
'*'.
perform bdc_field using 'RF05A-NEWBS'
'31'.
perform bdc_field using 'RF05A-NEWKO'
'9001'.
perform bdc_dynpro usin