09-19-2006 1:45 PM
Hi..
I am showing you the following piece of code whic one of my peers has written but I am unable to understand the scrolloing part :-
LOOP AT vit_ekpo1 WHERE ebeln = lit_lips-vgbel.
l_line_no = l_line_no + 1.
IF vit_ekpo1-ebelp = lit_lips-vgpos.
vit_ekpo1-flag = 'X'.
MODIFY vit_ekpo1 TRANSPORTING flag.
EXIT.
ENDIF.
ENDLOOP.
l_cno = l_line_no.
Calculation for table controller
CONCATENATE 'LIPSD-G_LFIMG(0' l_cno ')' INTO l_fname.
WRITE lit_lips-lfimg TO l_lfimg UNIT lit_lips-meins.
For scrolling the table control
IF l_line_no > 3.
PERFORM sub_bdcfill USING :
space space space 'BDC_OKCODE' '=POPO_T',
'SAPMV50A' '0111' 'X' space space,
space space space 'RV50A-POSNR' l_cno,
space space space 'BDC_OKCODE' '=WEIT',
'SAPMV50A' '1000' 'X' space space.
MOVE 'LIPSD-G_LFIMG(01)' TO l_fname.
ENDIF.
I want to know what exactly does '=POPO_T' and '=WEIT' do and what is the logic behind seeting the condition > 3.
Any guesses are also welcome.
Thanks
09-19-2006 1:49 PM
Hello,
The scrolling should be handled by us,as follows.
U have to handle this ur self based on the size of ur table control.
If suppose ur table control fits 7 line items, then u have to handle the records from 8 the record.
For example,
ADD 1 TO w_line_i.
IF w_line_i > 7.
w_line_i = 1.
PERFORM bdc_dynpro USING 'SAPMM07M' '0421'.
PERFORM bdc_field USING 'BDC_OKCODE' '=NP'.
ENDIF.
Set a flag once the line item are greater than 7.
It depend on ur case.
Regards
09-19-2006 1:52 PM
Thank You Ravi!...but what does
'BDC_OKCODE' '=NP'.
imply?
And what is the function code to indicate a scrolling on the screen.
Thank You
09-19-2006 2:06 PM
This means that this Function Code is to be executed.
Now if you check the GUI status you would see this is assigned and internally this would be the same function code that is linked to scrolling
Hope this helps
Regards
Nishant