05-30-2008 2:00 PM
Hi all,
I am working on a BDC (MI04)which has 3 fields as header:
Document Number:
Date:
Fiscal Year.
After entering I get a screen having default Material Number, its description and its serial number. There is one field named QTY where I need to push the value through BDC.
But the issue is that I am not able to reach to that Material Code to push the qty value. I am getting the Material Code and its serial number in the text file from user.
May some times the given material code in on the NEXT PAGE (P+). So dont know how to go to the next page and push the qty in front of the correct material code..
Please help. Its very very urgent.
Thanks in Advance.
-=Maddu=-
05-30-2008 2:07 PM
Hi Pal,
When u do the BDC recording u can do the recording in such a way that it prompts on the Material Code element.
In the Program u can get the value in an Internal Table ..
and assign the value to the Bdctab at that point.
Hope this helps.
Thanx,|
Navin.
05-30-2008 2:19 PM
There is a "position" icon (function code ABA) to move the desired line on top of the screen (so use 01 in your BDC)
You can find the line number in the tables IKPF/ISEG.
Regards
PS: Why didn't you use BAPIs like BAPI_MATPHYSINV_COUNT ?
06-02-2008 10:56 AM
Could you please elobrate it more. If on every page say 6 items are coming and I need to update the 8th record, which will come on the second page then how wil I be able to reach to the recoud going by logic.
Please help.
06-02-2008 11:01 AM
Hi,
PERFORM BDC_FIELD USING 'BDC_OKCODE'
'=P+'. for next page
PERFORM BDC_FIELD USING 'BDC_OKCODE'
'=P++'. for last page
PERFORM BDC_FIELD USING 'BDC_OKCODE'
'=P-'. for previous page
PERFORM BDC_FIELD USING 'BDC_OKCODE'
'=P+'. for first page
regards,
muralidhar.
06-02-2008 11:30 AM
06-02-2008 12:20 PM
Try something like
perform bdc_dynpro using 'SAPMM07I' '0731'.
perform bdc_field using 'BDC_CURSOR'
'ISEG-ERFMG(01)'.
perform bdc_field using 'BDC_OKCODE'
'=KLA'. " Menu goto/position
perform bdc_dynpro using 'SAPMM07I' '1701'.
perform bdc_field using 'BDC_CURSOR'
'RM07I-ZEILE'.
perform bdc_field using 'BDC_OKCODE'
'=ENT2'.
perform bdc_field using 'RM07I-ZEILE'
'8'. " give the "iseg-zeile" of the record to fill
perform bdc_dynpro using 'SAPMM07I' '0731'.
perform bdc_field using 'BDC_CURSOR'
'ISEG-ERFMG(01)'. " fill line 1 displayed
Regards