Hi there Gurus

i need ur help gurus,
my user wants me to customize CA51 t-code,
they want me to change the out put format to be in alv grid, or some thing like excel format,
so that they can download easyly the format,
i went throught the codes, i found that there are too many write statements,
i wounder how to change the format.
it is kind of urgent,
need ur advice as soon as possible,
thank you gurus.

hi
just try to find the table from which it is printing the output data and pass that table to fm ' reuse_alv_grid_display'.
regards
vijay
reward points if helpful

Similar Messages

  • Hi there Gurus having problem with customizing CA51

    hi there Gurus,
    i was required to customize the CA51 program .
    i try to copy the program , but i'm facing alot of errors.
    (customized)
    Program ZRCPDRK00     
    Field "PN_PLNTY" is unknown. It is neither in one of the specified          
    tables nor defined by a "DATA" statement.          
    the actual program is RCPDRK00 looks fine,
    please advice me regarding this,
    i even try to define the pn_plnty in the data statement, but still encounter this error.
    please give me some solutions.
    thank you

    Look in the MIDI event list (key: E) for volume messages (control nr 7) and delete those. If it keeps happening after that, unplug your MIDI controller(s). Chances are there's a wonky volume slider on it that sends a MIDI message any time you hit your keys vigorously...

  • Hi gurus is there any program that shows the history material

    hi there gurus,
    is there any report or porgram that shows the history of the material for the past 12 months.
    hope to hear from you guyz as soon as possible, since this is kind of very urgent.
    thanks,
    vasan

    hi gurus,
    i want a report something shows this things in it,
    Materials No
    MBEW-matnr
    makt-maktx
    MBEW-LBKUM
    UOM
    MARA-MEINS
    Total value (MYR)
    MBEW-SALK3
    Consumed Past 12 months      Consumed Past 12 months
    qty                                          value (MYR)
    Consumption(Qty) MB51 sub cond mvt 543 Consumption
    DAYS SINCE CONSUMPTION
    i try to create a program but having some problem with it,
    if its possible for u to have a look into my coding,and giveme some advice with it.
    thanks.

  • F110 - PAYMENT RUN ERRORS

    Hio there Gurus
    When am running f110 status showing Parameters have been entered, Payment proposal has been created, Payment run has been carried out and vendor line items have been cleared. However, there is a shortage in the amount of money that the vendor recieved. i've checked the following:
    1. PO amount - no errors
    2. Goods recieved - no errors
    3. Involves - no errors
    4. vendor line items - cleared for the correct amount
    please help as i do not know where the  problem lies.thanks.

    Hi,
    Since you have already done the payment run, go to F110 and select the payment tab. You will get the job name for the payment run. Double click on the line and it will take you to the entries made.
    Alternatively, you can run FBL1N report for the vendor and view the payment entry for the vendor. Double click on the line and go to the document overview.
    In both the above cases, you will know from the accounting entry if any deduction has ben made at the time of F110.
    Please revert for any clarification.
    Thanks and Regards,
    Anit

  • Custom Icon

    Hi there Gurus,
    I need to make a custom cursor. I creat a gif, import it into
    the cast, click insert media element and select cursor. I then
    select the gif I want as the cursor, ... however I am not able to
    check the 32 pixel option.
    My dilema is ... I really need the larger cursor. Is this
    possible and what am I doing wrong?
    If not , is there a way to hide the real cursor so I can
    simply have a sprite follow the mouse pointer?
    Cheers very much

    As far as I know the images used by a cursor need to be 8
    bit.
    Oh, sorry. I see what you mean. Are you on mac or win?

  • How to dispaly datas from the table, base on the selection screen

    hi there gurus,
    im currently developing a stock aging report,
    i have completed one program but it do not allow me to excutes the program althought the syntax is correct.
    i would to get some ideas from you, regarding how to extract the datas from the tables?
    my selction screen will be, mat number, date, and gl account.
    and the out put datas are, mbew-matnr, makt-maktx, mbew-lbkum, mara_meins, mbew-salk3,and the consumptions for the past 12months and the values for it.
    can u plz guide me with this,
    thank you,.
    this is kind of very urgent program that i need to finish , plz help me.

    here is the total code the i do
    REPORT  ZSTK_AGING_REP2.
    *TABLES
    TABLES: mseg,
            mara,
            makt,
            SKAT,
            SKA1,
            MARV,
            T001,
            T030,
            T149D,
            AM07M,
            MCMSEG,
            T001K,
            T001W,
            T134M,
            vbak,
            mbew,
    mcon, rmcb0, marc, t024w,  mvke, v134w, t438a, propf, maprf, t000, t024e
    , tvko.
    DATA: BEGIN OF ta_material OCCURS 2,
           werks LIKE mard-werks,
           lgort LIKE mard-lgort,
           matnr LIKE mard-matnr,
           labst LIKE mard-labst,
           umlme LIKE mard-umlme,
           insme LIKE mard-insme,
           einme LIKE mard-einme,
           speme LIKE mard-speme,
           retme LIKE mard-retme,
           verpr LIKE mbew-verpr,
           maktx LIKE makt-maktx,
           meins LIKE mara-meins,
          bukrs LIKE t001-bukrs,
          konto LIKE t030-konts,
          butxt LIKE t001-butxt,
          txt50 LIKE skat-txt50,
          MABTR LIKE MCMSEG-DMBTR,
          SKBTR LIKE MCMSEG-DMBTR,
          WAERS LIKE T001-WAERS,
          WAER2 LIKE T001-WAERS,
          BWKEY LIKE MBEW-BWKEY,
          LBKUM LIKE MBEW-LBKUM,
         MEINS LIKE MARA-MEINS,
             SALK3 LIKE MBEW-SALK3,
             WAERS1 LIKE T001-WAERS,
             BUKRS1 LIKE T001-BUKRS,
             KONTO1 LIKE T030-KONTS,
            lbkum LIKE mbew-lbkum,
              erdat LIKE vbak-erdat,
          END OF ta_material.
    DATA: BEGIN OF ta_mseg OCCURS 2,
            mblnr LIKE mseg-mblnr,
    *->Begin of KL02+ -
            mjahr like mseg-mjahr,
            zeile like mseg-zeile,
    *->End of KL02+ -
            meins LIKE mseg-meins,
            menge LIKE mseg-menge,
            werks LIKE mseg-werks,
            lgort LIKE mseg-lgort,
            matnr LIKE mseg-matnr,
            budat LIKE mkpf-budat,
            saknr LIKE SKA1-SAKNR,
          END OF ta_mseg.
    single recs based on MATNR
    DATA: BEGIN OF i_matnr OCCURS 0,
            werks LIKE mard-werks,
            lgort LIKE mard-lgort,
            matnr LIKE mard-matnr,
            maktx LIKE makt-maktx,
            mblnr LIKE mseg-mblnr,
            verpr LIKE mbew-verpr,
            labst LIKE mard-labst,                    "Valuated stock with
    *unrestricted use
            umlme LIKE mard-umlme,                    "Stock in transfer
    *(from one storage location to another)
            insme LIKE mard-insme,                    "Stock in quality
    *inspection
            einme LIKE mard-einme,                    "Total Stock of All
    *Restricted Batches
            speme LIKE mard-speme,                    "Blocked stock
            retme LIKE mard-retme,                    "Blocked Stock Returns
            meins LIKE mara-meins,                    "base unit
          bukrs LIKE t001-bukrs,
          konto LIKE t030-konts,
          butxt LIKE t001-butxt,
          txt50 LIKE skat-txt50,
          MABTR LIKE MCMSEG-DMBTR,
          SKBTR LIKE MCMSEG-DMBTR,
          WAERS LIKE T001-WAERS,
          WAER2 LIKE T001-WAERS,
          BWKEY LIKE MBEW-BWKEY,
          LBKUM LIKE MBEW-LBKUM,
         MEINS LIKE MARA-MEINS,
             SALK3 LIKE MBEW-SALK3,
             WAERS1 LIKE T001-WAERS,
             BUKRS1 LIKE T001-BUKRS,
             KONTO1 LIKE T030-KONTS,
            lbkum LIKE mbew-lbkum,
           END OF i_matnr.
    recs based on MBLNR
    DATA: BEGIN OF i_mblnr OCCURS 0,
            mblnr LIKE mseg-mblnr,
            werks LIKE mseg-werks,
            lgort LIKE mseg-lgort,
            matnr LIKE mseg-matnr,
            menge LIKE mseg-menge,
            meint LIKE mseg-meins,
            budat LIKE mkpf-budat,
         bukrs LIKE t001-bukrs,
         konts LIKE t030-konts,
         butxt LIKE t001-butxt,
         txt50 LIKE skat-txt50,
         MABTR LIKE MCMSEG-DMBTR,
         SKBTR LIKE MCMSEG-DMBTR,
         WAERS LIKE T001-WAERS,
         WAER2 LIKE T001-WAERS,
         BWKEY LIKE MBEW-BWKEY,
          LBKUM LIKE MBEW-LBKUM,
         MEINS LIKE MARA-MEINS,
             SALK3 LIKE MBEW-SALK3,
             WAERS1 LIKE T001-WAERS,
             BUKRS1 LIKE T001-BUKRS,
             KONTO1 LIKE T030-KONTS,
           END OF i_mblnr.
    TYPES: BEGIN OF t_mat,
            lgort LIKE mseg-lgort,
            werks LIKE mseg-werks,
            matnr LIKE mseg-matnr,
            mblnr LIKE mseg-mblnr,
            maktx LIKE makt-maktx,
            meins LIKE mara-meins,
    meng0 LIKE mbew-lbkum,
    value0 LIKE mbew-salk3,
           meng0  LIKE mard-labst,                   "0 to 10 days
           value0 LIKE mseg-dmbtr,
           meng1  LIKE mard-labst,                   "11 to 30 days
           value1 LIKE mseg-dmbtr,
           meng2 LIKE mard-labst,                   "31 to 60 days
           value2 LIKE mseg-dmbtr,
           meng3 LIKE mard-labst,                   "61-90
           value3 LIKE mseg-dmbtr,
           meng4 LIKE mard-labst,                   "90 days onwards
           value4 LIKE mseg-dmbtr,
           END OF t_mat.
    DATA: i_mat2 TYPE t_mat OCCURS 0 WITH HEADER LINE.
    TYPES: BEGIN OF t_mat2,
            lgort LIKE mard-lgort,                    " storage location
            cnt0(5),
            cnt1(5),
            cnt2(5),
            cnt3(5),
            cnt4(5),
       meng0 LIKE mbew-lbkum,
    value0 LIKE mbew-salk3,
           meng0  LIKE mard-labst,                   "0 to 10 days
           value0 LIKE mseg-dmbtr,
           meng1  LIKE mard-labst,                   "11 to 30 days
           value1 LIKE mseg-dmbtr,
           meng2 LIKE mard-labst,                   "31 to 60 days
           value2 LIKE mseg-dmbtr,
           meng3 LIKE mard-labst,                   "61-90
           value3 LIKE mseg-dmbtr,
           meng4 LIKE mard-labst,                   "90 days onwards
           value4 LIKE mseg-dmbtr,
           END OF t_mat2.
    DATA: i_matsum TYPE t_mat2 OCCURS 0 WITH HEADER LINE.
    DATA:  w_mengb TYPE mbew-lbkum,
           w_workqyt TYPE mbew-lbkum,
           w_index TYPE sy-tabix,
    *DATA: w_mengb TYPE mard-labst,     "tmp Balance qty
         w_workqty TYPE mard-labst,   "Work qty
         w_index TYPE sy-tabix,
          w_days(5)  TYPE n,           "duration difference (days)
          w_mths(5)  TYPE n,           "duration difference (mths)
          w_dat1 TYPE sy-datum,        "date
          w_dat2 TYPE sy-datum,        "today's date
          w_detl(1) TYPE c,
          w_summ(1) TYPE c,
          w_denom TYPE i,
          w_numer TYPE i,
          w_conv TYPE i,
          w_ttlcnt TYPE i,
          w_cnt TYPE i,
          v_topofpage(1),
         w_meng LIKE mard-labst,
           w_meng LIKE mbew-lbkum,
    *sapscript values
          w_title(20) TYPE c.              "Summary / Detail Report
    DATA: lv_peinh LIKE mbew-peinh,  "Price Unit
          lv_verpr LIKE mbew-verpr.  "Moving Price
    proram comes here
    SELECTION-SCREEN BEGIN OF BLOCK blk1 WITH FRAME TITLE text-001.
    SELECT-OPTIONS: s_werks FOR mseg-werks,
                    s_lgort FOR mseg-lgort,
                    s_matnr FOR mara-matnr,
                    s_saknr FOR ska1-saknr,
                    S_ERDAT FOR VBAK-ERDAT.
    PARAMETERS: pck_detl RADIOBUTTON GROUP rep1,
                pck_summ RADIOBUTTON GROUP rep1,
                pck_dtsm RADIOBUTTON GROUP rep1 DEFAULT 'X'.
    SELECTION-SCREEN END OF BLOCK blk1.
    top of the page
      TOP-OF-PAGE.
      PERFORM  f_top_of_page.
      FORM f_top_of_page .
      IF v_topofpage = 'D'.
    *-->Report header for detail report
        WRITE:/2 'Printed By :', sy-uname,
               80 'Stock Aging Report - Detail',
               180 'Printed on:', sy-datum, sy-timlo,
               220 'Page:', sy-pagno.
        WRITE:/,/,/.
        WRITE:/2 'Storage',
               10 'Matl ID',
               22 'Matl Description',
               61 'UOM',
               78 '<--=<QTY ON THIS DATE -->',
              78 '<-- =< 10 days -->',
              112 '<--11 to 30 days -->',
              148 '<--31 to 60 days -->',
              181 '<--61 to 90 days -->',
              216 '<-- > 90 days -->',
               /2 'Location',
               76 'Qty',
               92 'Value'.
              112 'Qty',
              128 'Value',
              148 'Qty',
              164 'Value',
              181 'Qty',
              195 'Value',
              216 'Qty',
              231 'Value'.
        WRITE:/2 sy-uline(235).
      ELSE.
    *-->Report header for Summary report
        WRITE:/2 'Printed By :', sy-uname,
               80 'Stock Aging Report - Summary',
               180 'Printed on:', sy-datum, sy-timlo,
               220 'Page:', sy-pagno.
        WRITE:/,/,/.
        WRITE:/2 'Storage',
               10 'Matl ID',
               22 'Matl Description',
               61 'UOM',
               78 '<--< QTY ON THIS DATE -->',
              78 '<-- < 10 days -->',
              112 '<--11 to 30 days -->',
              148 '<--31 to 60 days -->',
              181 '<--61 to 90 days -->',
              216 '<-- > 90 days -->',
               /2 'Location',
               76 'Qty',
               92 'Value'.
              112 'Qty',
              128 'Value',
              148 'Qty',
              164 'Value',
              181 'Qty',
              195 'Value',
              216 'Qty',
              231 'Value'.
        WRITE:/2 sy-uline(235).
      ENDIF.
    ENDFORM.                    " f_top_of_page
    *start-of-selection
    *PERFOM f_data_selection.
    FORM f_data_selection.
      SELECT a~werks
             a~lgort
             a~matnr
            a~saknr
            a~lbkum
            a~erdat
            a~labst
             a~umlme
             a~insme
             a~einme
             a~speme
             a~retme
           b~verpr    "this field no long been used
             c~maktx
             d~meins
             INTO CORRESPONDING FIELDS OF TABLE ta_material
             FROM mard AS a
             INNER JOIN makt AS c ON amatnr = cmatnr
             INNER JOIN mara AS d ON amatnr = dmatnr
             WHERE a~matnr IN s_matnr
               AND a~werks IN s_werks
               AND a~lgort IN s_lgort
              AND a~saknr IN s_saknr
              AND a~erdat IN s_erdat
               AND c~spras = 'EN'.
    *--> SC01 - End  of Insertion **
    *-->Select material documents
      SELECT a~mblnr
            a~mjahr
            a~zeile
            a~meins
            a~menge
            a~werks
            a~lgort
            a~matnr
            b~budat
            INTO CORRESPONDING FIELDS OF TABLE ta_mseg
      FROM mseg AS a INNER JOIN mkpf AS b
      ON amblnr = bmblnr
      AND amjahr = bmjahr
      FOR ALL ENTRIES IN ta_material
      WHERE matnr = ta_material-matnr
      AND a~werks = ta_material-werks
      AND a~lgort = ta_material-lgort
      AND algort NE aumlgo
      AND a~shkzg = 'S'
      AND a~smbln EQ space
      AND a~smblp EQ space.
    *--> SC03 - Start of Insertion **
    If MBLNR exist in MSEG-SMBLN and this
    record's SHKZG = 'H'. Remove it from the table.
    This is becuase this particular record has already been reverse.
      LOOP AT ta_mseg.
        SELECT SINGLE *
                 FROM mseg
                WHERE smbln = ta_mseg-mblnr
    *->Begin of KL02+ -
                  and SMBLP = ta_mseg-zeile.
                 AND shkzg = 'H'.  "return.           " KL02-
    *->End of KL02+ -
        IF sy-subrc = 0.
          DELETE ta_mseg.
        ENDIF.
      ENDLOOP.
    *--> SC03 - Enf   of Insertion **
    ENDFORM.                    " f_data_selection
    *IMPORTANT , NEED TO CHECK LATER
    FORM f_data_preparation.
    *-->Append data for report details
      LOOP AT ta_material.
        DATA: ta_msegtemp LIKE ta_mseg OCCURS 2 WITH HEADER LINE.
    *-->Loop at all material documents into a temp table
        REFRESH ta_msegtemp. CLEAR ta_msegtemp.
        LOOP AT ta_mseg WHERE matnr = ta_material-matnr AND
                              werks = ta_material-werks AND
                              lgort = ta_material-lgort.
          ta_msegtemp = ta_mseg. APPEND ta_msegtemp.
        ENDLOOP.
    *-->Add up all the stock for the material
        CLEAR w_mengb.
        w_mengb = ta_material-labst +
                        ta_material-umlme +
                        ta_material-insme +
                        ta_material-einme +
                        ta_material-speme +
                        ta_material-retme.
        IF w_mengb IS INITIAL.
          CONTINUE.
        ENDIF.
    *-->sort msegtemp by posting date
        SORT ta_msegtemp BY budat DESCENDING.
    *-->get the values from the material documents into the report output
        LOOP AT ta_msegtemp.
    *->Begin of KL02- -
         CALL FUNCTION 'HRCM_TIME_PERIOD_CALCULATE'
           EXPORTING
             begda               = ta_msegtemp-budat
             endda               = sy-datum
           IMPORTING
            NOYRS               =
             nomns               = w_mths
             nodys               = w_days
          EXCEPTIONS
            invalid_dates       = 1
            overflow            = 2
            OTHERS              = 3
    *->End of KL02- -
    *->Begin of KL02+ -
    *-->Get the days difference btw two dates
          clear w_days.
          w_days = sy-datum - ta_msegtemp-budat.
    *--> Include today's date into calculation
          w_days = w_days + 1.
    *->End of KL02+ -
    check base unit, do conversion
          IF ta_material-meins <> ta_msegtemp-meins.
            CALL FUNCTION 'MD_CONVERT_MATERIAL_UNIT'
              EXPORTING
                i_matnr              = ta_material-matnr
                i_in_me              = ta_msegtemp-meins
                i_out_me             = ta_material-meins
                i_menge              = ta_msegtemp-menge
              IMPORTING
                e_menge              = ta_msegtemp-menge
              EXCEPTIONS
                error_in_application = 1
                error                = 2
                OTHERS               = 3.
          ENDIF.
    *--> SC01 - Start of Insertion **
          SELECT SINGLE peinh
                        verpr
                   INTO (lv_peinh,
                         lv_verpr)
                   FROM mbew
                  WHERE matnr = ta_material-matnr
                    AND bwkey = ta_material-werks.
          IF sy-subrc = 0.
            ta_material-verpr = lv_verpr.
          ENDIF.
    *--> SC01 - End   of Insertion **
    *-->check whether the mseg value is LE than the stock value
          IF ta_msegtemp-menge LE w_mengb.
    *-->Days < 10 days
            IF w_days  LE 1 AND w_days EQ 366.
              i_mat2-meng0 = i_mat2-meng0 + ta_msegtemp-menge.
              IF NOT lv_peinh EQ 0.
                i_mat2-value0 = ( i_mat2-meng0 / lv_peinh ) *
    ta_material-verpr."+SC01
              ENDIF.
    **-->Days 11 - 30 days
           ELSEIF w_days >= 11 AND w_days =< 30.
             i_mat2-meng1 = i_mat2-meng1 + ta_msegtemp-menge.
             IF NOT lv_peinh EQ 0.
               i_mat2-value1 = ( i_mat2-meng1 / lv_peinh ) *
    *ta_material-verpr."+SC01
             ENDIF.
    **-->Days 31-60 days
           ELSEIF w_days >= 31 AND w_days =< 60.
             i_mat2-meng2 = i_mat2-meng2 + ta_msegtemp-menge.
             IF NOT lv_peinh EQ 0.
               i_mat2-value2 = ( i_mat2-meng2 / lv_peinh ) *
    *ta_material-verpr."+SC01
             ENDIF.
    **-->Days 61-90 days
           ELSEIF w_days >= 61 AND w_days =< 90.
             i_mat2-meng3 = i_mat2-meng3 + ta_msegtemp-menge.
             IF NOT lv_peinh EQ 0.
               i_mat2-value3 = ( i_mat2-meng3 / lv_peinh ) *
    *ta_material-verpr.
             ENDIF.
    **-->Days > 90 days
           ELSEIF w_days > 90.
             i_mat2-meng4 = i_mat2-meng4 + ta_msegtemp-menge.
             IF NOT lv_peinh EQ 0.
               i_mat2-value4 = ( i_mat2-meng4 / lv_peinh ) *
    *ta_material-verpr.
             ENDIF.
           ENDIF.
    *->End of KL002+
            w_mengb = w_mengb - ta_msegtemp-menge.
          ELSE.
            IF NOT w_mengb LE 0 .
                 IF NOT lv_peinh EQ 0.
    **->End of KL001+
                   i_mat2-value0 = ( i_mat2-meng0 / lv_peinh )
    *ta_material-verpr."+SC01
    **->Begin of KL001+
                 ENDIF.
               ELSEIF w_days GE 22.
                 i_mat2-meng3 = i_mat2-meng3 + w_mengb.
                 IF NOT lv_peinh EQ 0.
                   i_mat2-value3 = ( i_mat2-meng3 / lv_peinh )
    *ta_material-verpr.
                 ENDIF.
    **->End of KL001+
               ENDIF.
    **--> SC02 - End  of Insertioin **
           ENDIF.
    *->End of KL002-
    *->Begin of KL002+
    *--> < 10 days
                     IF w_days EQ 1 AND w_days LE 366.
              i_mat2-meng0 = i_mat2-meng0 + ta_msegtemp-menge.
              IF NOT lv_peinh EQ 0.
                i_mat2-value0 = ( i_mat2-meng0 / lv_peinh ) *
    ta_material-verpr."+SC01
              ENDIF.
             ELSEIF w_days >= 11 AND w_days =< 30.
               i_mat2-meng1 = i_mat2-meng1 + w_mengb.
               IF NOT lv_peinh EQ 0.
                 i_mat2-value1 = ( i_mat2-meng1 / lv_peinh ) *
    *ta_material-verpr.
               ENDIF.
    **--> 31 - 60 days
             ELSEIF w_days >= 31 AND w_days =< 60.
               i_mat2-meng2 = i_mat2-meng2 + w_mengb.
               IF NOT lv_peinh EQ 0.
                 i_mat2-value2 = ( i_mat2-meng2 / lv_peinh ) *
    *ta_material-verpr.
               ENDIF.
    **--> 61 - 90 days
             ELSEIF w_days >= 61 AND w_days =< 90.
               i_mat2-meng3 = i_mat2-meng3 + w_mengb.
               IF NOT lv_peinh EQ 0.
                 i_mat2-value3 = ( i_mat2-meng3 / lv_peinh ) *
    *ta_material-verpr.
               ENDIF.
    **--> > 90 days
             ELSEIF w_days > 90.
               i_mat2-meng4 = i_mat2-meng4 + w_mengb.
               IF NOT lv_peinh EQ 0.
                 i_mat2-value4 = ( i_mat2-meng4 / lv_peinh ) *
    *ta_material-verpr.
               ENDIF.
              ENDIF.
    *->End of KL002+
              w_mengb = 0.
            ENDIF. " check stock value NE zero
          ENDIF.   "check Mat doc amount is LE than the stock value
    ENDIF.
        ENDLOOP. " msegtemp
    *-->append i_mat2 values
        i_mat2-werks = ta_material-werks.
        i_mat2-lgort = ta_material-lgort.
        i_mat2-matnr = ta_material-matnr.
        i_mat2-maktx = ta_material-maktx.
        i_mat2-meins = ta_material-meins.
        APPEND i_mat2. CLEAR i_mat2.
      ENDLOOP. " ta_material
    *-->Append data for summary data
      DATA: i_lgort LIKE i_mat2 OCCURS 2 WITH HEADER LINE.
      i_lgort[] = i_mat2[].
      SORT i_lgort BY werks lgort.
      DELETE ADJACENT DUPLICATES FROM i_lgort COMPARING werks lgort.
      DATA: v_cnt0(5), v_cnt1(5), v_cnt2(5), v_cnt3(5), v_cnt4(5),
            v_value0 LIKE i_matsum-value0.
           v_value1 LIKE i_matsum-value1,
           v_value2 LIKE i_matsum-value2,
           v_value3 LIKE i_matsum-value3,
           v_value4 LIKE i_matsum-value4.
      LOOP AT i_lgort.
        CLEAR v_cnt0. CLEAR v_value0.
      CLEAR v_cnt1. CLEAR v_value1.
       CLEAR v_cnt2. CLEAR v_value2.
       CLEAR v_cnt3. CLEAR v_value3.
       CLEAR v_cnt4. CLEAR v_value4.
        LOOP AT i_mat2 WHERE lgort = i_lgort-lgort AND
                             werks = i_lgort-werks.
          IF NOT i_mat2-meng0 IS INITIAL.
            v_cnt0 = v_cnt0 + 1.
            v_value0 = v_value0 + i_mat2-value0.
          ENDIF.
         IF NOT i_mat2-meng1 IS INITIAL.
           v_cnt1 = v_cnt1 + 1.
           v_value1 = v_value1 + i_mat2-value1.
         ENDIF.
         IF NOT i_mat2-meng2 IS INITIAL.
           v_cnt2 = v_cnt2 + 1.
           v_value2 = v_value2 + i_mat2-value2.
         ENDIF.
         IF NOT i_mat2-meng3 IS INITIAL.
           v_cnt3 = v_cnt3 + 1.
           v_value3 = v_value3 + i_mat2-value3.
         ENDIF.
         IF NOT i_mat2-meng4 IS INITIAL.
           v_cnt4 = v_cnt4 + 1.
           v_value4 = v_value4 + i_mat2-value4.
         ENDIF.
        ENDLOOP.
        CLEAR i_matsum.
        i_matsum-lgort = i_mat2-lgort.
        IF v_cnt0 NE space.
          i_matsum-cnt0 = v_cnt0.
          i_matsum-value0 = v_value0.
          APPEND i_matsum.
        ENDIF.
       CLEAR i_matsum.
       i_matsum-lgort = i_mat2-lgort.
       IF v_cnt1 NE space.
         i_matsum-cnt1 = v_cnt1.
         i_matsum-value1 = v_value1.
         APPEND i_matsum.
       ENDIF.
       CLEAR i_matsum.
       i_matsum-lgort = i_mat2-lgort.
       IF v_cnt2 NE space.
         i_matsum-cnt2 = v_cnt2.
         i_matsum-value2 = v_value2.
         APPEND i_matsum.
       ENDIF.
       CLEAR i_matsum.
       i_matsum-lgort = i_mat2-lgort.
       IF v_cnt3 NE space.
         i_matsum-cnt3 = v_cnt3.
         i_matsum-value3 = v_value3.
         APPEND i_matsum.
       ENDIF.
       CLEAR i_matsum.
       i_matsum-lgort = i_mat2-lgort.
       IF v_cnt4 NE space.
         i_matsum-cnt4 = v_cnt4.
         i_matsum-value4 = v_value4.
         APPEND i_matsum.
       ENDIF.
      ENDLOOP.
    ENDFORM.                    "f_data_preparation
    *IMPORTANT , NEED TO CHECK LATER
    FORM f_display_data .
      IF pck_dtsm = 'X'.
    *-->Display detail
        v_topofpage = 'D'.
        PERFORM f_display_detail.
    *-->display summary
        v_topofpage = 'S'.
        NEW-PAGE.
        PERFORM f_display_summary.
      ELSEIF pck_detl = 'X'.
    *-->Display detail
        v_topofpage = 'D'.
        PERFORM f_display_detail.
      ELSEIF pck_summ = 'X'.
    *-->display summary
        v_topofpage = 'S'.
        PERFORM f_display_summary.
      ENDIF.
    ENDFORM.                    " f_display_data
    FORM f_display_detail .
      v_topofpage = 'D'.
      SORT i_mat2 BY werks lgort.
    *DATA: v_count(5),
    DATA: v_count,
            v_va1 LIKE i_mat2-value0.
           v_va2 LIKE i_mat2-value0,
           v_va3 LIKE i_mat2-value0,
           v_va4 LIKE i_mat2-value0,
           v_va5 LIKE i_mat2-value0.
      LOOP AT i_mat2.
        WRITE:/2 i_mat2-lgort,
              10 i_mat2-matnr,
              22 i_mat2-maktx(38),
              61 i_mat2-meins,
              64 i_mat2-meng0,
              82 i_mat2-value0.
             100 i_mat2-meng1,
             118 i_mat2-value1,
             136 i_mat2-meng2,
             154 i_mat2-value2,
             169 i_mat2-meng3,
             186 i_mat2-value3,
             204 i_mat2-meng4,
             222 i_mat2-value4.
    *-->Set counter and add up all values by lgort
        v_count = v_count + 1.
         v_va1 = v_va1 + i_mat2-value0.
       v_va2 = v_va2 + i_mat2-value1.
       v_va3 = v_va3 + i_mat2-value2.
       v_va4 = v_va4 + i_mat2-value3.
       v_va5 = v_va5 + i_mat2-value4.
        AT END OF lgort.
          WRITE:/10 'Cnt:',
                 15 v_count,
                 55 'Subtotal',
                 82 v_va1.
                118 v_va2,
                154 v_va3,
                186 v_va4,
                222 v_va5.
          CLEAR v_count. CLEAR v_va1.
         CLEAR v_va2. CLEAR v_va3. CLEAR v_va4. clear v_va5.
        ENDAT.
      ENDLOOP.
    ENDFORM.                    " f_display_detail
    FORM f_display_summary .
      v_topofpage = 'S'.
      LOOP AT i_matsum.
        IF NOT i_matsum-cnt0 IS INITIAL.
          WRITE:/2  i_matsum-lgort,
                 10 'Cnt:',15 i_matsum-cnt0,
                 82 i_matsum-value0.
        ENDIF.
       IF NOT i_matsum-cnt1 IS INITIAL.
         WRITE:/2  i_matsum-lgort,
                10 'Cnt:',15 i_matsum-cnt1,
                118 i_matsum-value1.
       ENDIF.
       IF NOT i_matsum-cnt2 IS INITIAL.
         WRITE:/2  i_matsum-lgort,
                10 'Cnt:',15 i_matsum-cnt2,
                154 i_matsum-value2.
       ENDIF.
       IF NOT i_matsum-cnt3 IS INITIAL.
         WRITE:/2  i_matsum-lgort,
                10 'Cnt:', 15 i_matsum-cnt3,
                186 i_matsum-value3.
       ENDIF.
       IF NOT i_matsum-cnt4 IS INITIAL.
         WRITE:/2  i_matsum-lgort,
                10 'Cnt:', 15 i_matsum-cnt4,
                222 i_matsum-value4.
       ENDIF.
      ENDLOOP.
    ENDFORM.                    " f_display_summary

  • How To Add InfoObject in the Data Selection Tab of InfoPackages in 2004s

    Hi Y'all!
    I would like to ask how to add an infoobject in the Data Selection Tab of the InfoPackage in 2004s.  It says its optional, this definintion of selection criteria for the infopackage.
    My apologies, I don't understand how this is done.  Surely, I would like, however, to understand how to add an infoobject in this data selection Tab of the InfoPackage in 2004s.
    Can any kind soul out there (gurus) please lend me your thoughts?
    Regards,
    Philips

    Hello Rajani!
    Thank you very mcuh for that!  I super appreciate it!  Can you prescribe how I can do this step by step please?  Where exactly in the DS can I locate this "field for selection" option in the DataSource?
    Regards!
    Philips

  • What is the meaning od general modification field in the obyc t-code.

    hi there gurus,
    can any one tell me what is the meaning of the general modification file din the obyc t-code,
    i wana know wht is that is used for n etc

    No -
    When I select 'flag message' I get a stylized flag in that column.
    These dashes are placed there by the mail application, not by me. They show up in some messages and not in others.
    Please don't just guess at the answer.
    G4 AGP Mac OS 9.2.x

  • How to add a Totals row in a dashboard

    Oracle Business Intelligence 11.1.1.6.4
    Hi there gurus,
    I would like to know how to add a totals row at the end of a pivot table within a dashboard. Notice that the column I need to sum up is a measure column and not a dimension one.
    Thank a lot.

    Alejandro Trejo wrote:
    Oracle Business Intelligence 11.1.1.6.4
    Hi there gurus,
    I would like to know how to add a totals row at the end of a pivot table within a dashboard. Notice that the column I need to sum up is a measure column and not a dimension one.
    Thank a lot.What do you mean? That's what you would always expect to aggregate. Click the sigma sign on the Rows section and it will sum up the measures column. If not, add the aggregation rule to the measure column. Otherwise, explain IN DETAIL what you did, don't assume that what you did was correct.

  • Where Used List with multiple/range of material

    Hi there Gurus!
    We have requirement to have multiple material on CS15(Where-used List Single-Level Material).
    IW13 won't work since there are spares/eqpmnt that has no PM Order yet.
    We are looking at developing SAP Query for this using but I am reluctant if this will work since it's from bottom going up.
    Has anyone tried this? Any tip/watchout?
    Your very valuable input is highly regarded and will be rewarded.
    Thanks a lot in advance!

    Hello Thyagarajan,
    Thanks for clarifying the requirement.
    Can only input one material in selection screen of CS15 and what we want is functionality to enable multiple material entry. Thanks!
    Hi Pete,
    Thanks for your input.
    When you copy CS15 and modify to enable multiple material entry, what other options did you consider before deciding on copying CS15? Does your other options include SAP Query? Do you think it will meet our reqmnt? Thanks!

  • ALV and Crystal Reports challenge

    Hi there Gurus.
    I already have posted this question in the Crystal section.
    Maybe some of you ABAP Guys knows the answer here.
    Our Customer have  Crystal Reports Template includet so that the user can choose to display ALV in a nice Crystal Report.
    We have made changes to the Template, and have included a logo in the top right corner of the Report Header Section.
    When the report is started from ALV , a new Report Header Section is made.. and my old Report Header Section is pushed down.
    The result is that the Logo no longer is in the top right corner.
    The new section is made from ABAP maybe, and has Report Title and some information about which parameters has been used.
    I am familiar in Crystal, but not so much in ABAP.
    Any suggestions on how to solve this ?
    We want the logo to be in the top right corner of the report.
    Best Regards
    Ingrid

    Serdar Simsekler   , you seem to know a lot about ALV and what is happening there.
    Do you know anything on where the logic is hidden, in what is passed on to Crystal form ALV?
    And where it is placed in the report. ?
    Best Regards Ingrid

  • HIERARCHY load from R/3 does not complete

    Hi there gurus,
    I am trying to load the 0GL_ACCOUNT hierarchy master data, but it never finishes. The attributes and text loaded successfully. We have already successfully installed the BC on R/3, then replicated it in BW, then installed the BC in BW. The master data loads fine into the PSA, but from the PSA, it just sits in yellow status and then finally times out.
    Any ideas please?
    Thx
    Charl

    Hi Charl,
         Can u just check the hierarchy for 0GL_ACCOUNT characteristic and compare it with R/3 hierarchy . If both are identical then you can manually turn it to green status.
    Regards,
    Prakash B

  • How to add the task bar containing some icons in to CM01 program

    hi there Gurus,
    i checked the program CM01, and found that all are include programs.
    now i would like to add some icons insides, such as sort, sum up etc.
    how could i do that?  please some one guide me.
    thanks

    hi there...
    u can do this... the way out is the use of customer exits.... search for a 'screen exit' in CM01 program, and simply put ur code in it....
    you can locate a proper customer exit in se81 transaction.
    For ur info, customer exits are hooks provided by SAP in their standard programs for the programmers to put in there own code as per the client requirements. they dont affect the standard code but simply addon another functionality.
    they are just like inheritance in oops.
    do reward if helpful or get back for further info.

  • Shortcut to switch between states?

    Hey there gurus,
    Simple one for you.
    Fireworks CS4. Mac OS 10.5.2.
    Is there a shortcut to switch between states?
    Thanks in advance.
    Tom

    Hey Tom,
    Glad to see you found your way to the keyboard shortcuts area. Here are a couple notes that might keep your Fireworks experience happy:
    •Try to keep your Fireworks files small... Don't have too many pages when you are going to be using a lot of states; I know it is tempting to have the entire project in one file... separating the different sections by pages and the different states of the sections by the states, but it will be worth your while to keep these files smaller and have multiple files in place of multiple pages. This will do wonders for helping the app remain consistent.
    •If you do choose to use multiple smaller files in place of large ones, use 'Command + `' (1 key left of 1/! key). This will let you flip through open pages. If you want to go in reverse, add shift (Command+Shift+`).
    •Try using the terminal command 'purge' if/when things get slow, this coupled with the aforementioned smaller files has helped me avoid crashes.
    •Make some custom tool panel layouts and save them in Window > Workspace Layouts > Save Current. If you want to update a workspace layout, just type the name of the layout you wish to save over.
    Best wishes and good luck with the clients!

  • CS5 problems - can anyone help?

    Hey there gurus/helpful individuals
    I work for a small design agency and we recently updated all of our machines to CS5.
    Whilst we have enjoyed the new features in many of the applications (mainly PS, AI & ID) we have also been frustrated by the speed reductions that we seem to be suffering.
    We are all on macs - a variety from imac i5 to Macpro Quad core.
    We have a variety of OS (leopard and snow leopard) and there doesn't seem to be any difference between these so I can't see our issues being OS related.
    Fireworks is behaving absolutely terribly - it recently seems to have become almost unusable. We cannot select items without dragging the cursor over them. Deselecting by clicking on an empty portion of the page doesn't work. The app gets stuck on the hand tool and cannot be changed to the pointer or anything else and needs a restart of FW to sort it out.
    InDesign is so slow with the redraw set to max that most of us have disabled that feature - is this right that on powerful macs this would result in such slow behaviour?
    One of my colleagues cannot type in PS - every time he switches to the type tool PS hangs for up to 30mins before crashing.
    Does anyone else have experience of these problems or have any idea of what might be causing them?
    All responses VERY much appreciated.
    Thanks in advance
    Tom

    Working on files from a central server will always be slower than working on them locally. CS5 has much higher system requirements as well. The combination of the two may be causing some of your bottlenecks. I would recommend a few things - first try working on some documents locally. See if you see any changes. Second - RAM, RAM, RAM. Stock Macs ship with 2 - 4 GB because that's the minimum! Back in the day you'd get a PowerMac with 16MB RAM expandable to 64MB - the first thing you did was put as much RAM in as you could afford. Granted with your mix of machines this will likely be an issue, but add as much as you can. I recently upgraded from a 1st Gen Intel iMac - maxed out at 4GB of RAM. It was absolutely no good to me for PS/AI/ID work when I got rid of it in December - this machine was only five years old. A nifty app called iFreeMem let me see that just running the OS and launching PS used most of my available RAM. And that was without even opening any documents or other apps. And check for scratch size on the local disks - those running the apps. You need a good 20+ GB for the OS to manage things while you're running your apps, not to mention scratch space for PS.
    Also, while running mixed OS versions won't necessarily cause any problems, it's a pain to manage and troubleshoot issues if everyone is running a different OS version. Even if I can't keep our file server, or bosses machine up-to-date, I at least keep the artists all running the same software and hardware.
    I always try to invest in the hardware first - then milk it for as long as I can. Since it sounds like most of your macs are at least of the leopard generation, I don't think you should be having too many issues. But RAM and networking sound to me like they're the culprits. The Gigabit switch should help, but I'd strongly recommend looking at RAM and your workflow. Hope this helps.

Maybe you are looking for

  • Max No of Requests Wait ????

    I am on WAS 700 in SM51 --> Select Application Server >Go to >Server Name >Information >Queue Information. The table shows table of 6 coloumns. One of the coloumn of the table is 'Max No of Requests Wait ". What it is ? Max number requested at peak t

  • Deploy SharePoint 2010 Sandbox solution to SharePoint 2013

    Hi All,             I have sand-box solution which is developed in  Visual Studio 2010 for  SharePoint 2010 ,And it is specially developed for branding the SharePoint 2010  site. Now I  need to add the sandbox solution to SharePoint 2013 Site.       

  • Column J head alignment can't be printed

    How can I fix my problem in printing head alignment? Column J always can't be printed. I use Canon Pixma IP1200. My computer OS is Windows 7. Thanks

  • Airport Extreme and HP 5MP printing

    I have tried to get my HP 5MP printing through the new Extreme unit, but while the computer seems to see the printer, nothing prints. It works fine through the iMac USB port, but not through the Extreme USB port. iMac 17" non-Intel   Mac OS X (10.4.6

  • How to download Master Collection CS6

    Hello, I have a licence for Master Collection CS6 6.0 but I cannot find where to download it from! Can anyone help?