12-20-2012 4:51 AM
Hi experts ,
I have created a button in PF STATUS application toolbar, if I press the button
I want to read all values entered in manual field and do some calculations in classical report.
Without using GET CURSOR Method. Is there any functionality to get all the values entered
in the manual field and to save all the values in the customized table.
Thanks.
12-20-2012 4:57 AM
hi,
you can use sy-lisel method in at user command event.
Please google it out for sy-lisel method.
Its easy.
hope it helps,
Vinoth
12-20-2012 5:20 AM
Hi,
suppose a record contains following fields which takes from ztable
Freight , netvalue
in the above Freight in the manual entry field . it may contain with blank or without blank
if i enter some value in the manual entry field and if i press the 'sub' button in application tool bar
it should calculate the net value and after i click 'save' button it must save in ztable.
in my case if i enter the manual entry for records which is blank and if i press 'sub' button its
calculating for first manual entry record and not for the remaining manual enter records.
if i press the save button it saves only with first manual entry for all the records and it updates one by one . but i need to save All in one time .
This is code I have used
START-OF-SELECTION.
SET PF-STATUS 'STATUS'.
DATA:VALUE(35).
DATA:FIELD(35).
AT USER-COMMAND.
*FORM USER_COMMAND USING R_COMM LIKE SY-UCOMM.
R_UCOMM = SY-UCOMM.
GET CURSOR FIELD FIELD VALUE VALUE.
CASE R_UCOMM.
WHEN '&SUB'.
LOOP AT ITAB.
* ITAB-FREIGHT = VALUE.
IF ITAB-FREIGHT NE '0.00'
OR ITAB-DISC NE '0.00' OR ITAB-COMM NE '0.00'.
ITAB-NET = ITAB-PR00 + ITAB-ZHLL - ITAB-FREIGHT - ITAB-ZFNI
- ITAB-DISC - ITAB-COMM.
ITAB-REL = ITAB-NET * ITAB-FKIMG.
RELSUM = RELSUM + ITAB-REL.
ENDIF.
MODIFY ITAB.
ENDLOOP.
WHEN '&SAVE'.
LOOP AT ITAB.
CLEAR:KUNNR.
IF NOT ITAB-NET EQ '0.00'.
KUNNR = ITAB-KUNAG .
MOVE-CORRESPONDING ITAB TO ZSR_DISC.
ZSR_DISC-KUNNR = KUNNR.
MODIFY ZSR_DISC.
IF SY-SUBRC EQ 0.
MESSAGE 'Records updated' TYPE 'I'.
ENDIF.
ENDIF.
ENDLOOP.
WHEN '&F03'.
LEAVE SCREEN.
WHEN '&F15'.
LEAVE SCREEN.
WHEN '&F12'.
LEAVE SCREEN.
ENDCASE.
Please suggest your solutions.
Thanks in advance.
12-20-2012 4:59 AM
Could you elaborate your requirement . I mean in which screen , tcode, program you getting problem. Please put some screen shots explaining your requirement.
Regards,
Sudheer Kumar.
12-20-2012 6:39 AM
See the standard example "SAPBC406ILSS_INTERACTIVE_LIST1" AND "SAPBC406ILSS_INTERACTIVE_LIST2"
12-20-2012 6:48 AM
12-20-2012 7:02 AM
A standard report example for processing multiple lines in classical interactive list.
12-20-2012 7:17 AM
12-20-2012 7:24 AM
open se38 and look for a report like *bc406* and select the related program.