Export line items in excel

Hello Experts,
We want to export line items from a contract in SRM adding additional fields in the excel document, this because in description we have the 40 characters limit and our services description is bigger, so we are adding the long description in the NOTE section, but we need to export this to the excel document to add this to the legal contract.
Is there a way to do it? or any ideas of a workaround?
I would really appretiate your help
thanks in advance.

Hi,
why don't you try with  a custom program? Do you want to use standard export button functionality?
thanks,
sankar.

Similar Messages

  • Export worklist items into Excel

    Hi,
    I am trying to export my worklist items of ALBPM into Excel, can anyone guide me.
    -

    Hello sivam,
    If you want ot export all the instances in your workspace, you can use the OOTB feature as pointed out by Ruben.
    You need to click on the button next to the views dropdown. The button appears as a page with an inbound arrow.
    On clicking the button you will get the output options of exporting your workspace in PDF or CSV format.
    Hope this helps.
    Regards,
    Jaydev Doshi

  • Upload Sales order item from excel to SAP in VA01 thru frontend

    Hi,
    I am a front end user.
    SAP version 710.
    we enter sales order thru frontend in VA01 in SAP. The data is stored in excel.
    Currently the following is performed.
    Open VA01. In transaction entry screen ,
    Copy from Excel & Paste In SAP the following
    SAPID of the Customer
    PO No.
    PO Date
    Then copy and paste the line items from excel block by block i.e. depending on no. of line items seen in SAP per screen, copy that many lines from excel and Paste in SAP.
    Then select next block and
    SAVE the order.
    In excel there are many orders of different customers.
    I know litte bit of VBA.
    Can this be automated somehow.
    Pl. help.
    Thanks

    Hi Suhas,
    to automate the work in the SAP, it requires e.g. SAP GUI Scripting.
    1. Please check whether your client is allowed to SAP GUI Scripting. (ALT / F12 -> Options -> Scripting -> Enable Scripting)
    2. There should be only an indicator for Enable Scripting.
    3.The other two indicators by Notify When ... should be inactive.
    4.You would then be able to record a SAP GUI script. (ALT / F12 -> Script Recording and Playback... -> red dot)
    5.Please record all that to what you have to do it manually for first record in Excel.
    6.Stop recording (record and playback -> yellow dot)
    7.Please then present the results here in the forum for your script.
    8.Present us also your Excel sheet with some rows.
    Unfortunately I have no access to the VA01 transaction. But you can already read a lot in advance on the following link.:
    Re: Transferring data from Excel to SAP
    Regards,
    ScriptMan

  • Exporting large report to Excel format (90K lines)

    Hi,
    I am trying to export a 90K line report to excel format and I get that error messsage:
    Description : Une erreur d'application s'est produite sur le serveur. Les paramètres d'erreur personnalisés actuels pour cette application empêchent l'affichage à distance des détails de l'erreur de l'application (pour des raisons de sécurité). Cependant, ils peuvent être affichés par les navigateurs qui s'exécutent sur l'ordinateur serveur local.
    Détails: Pour permettre l'affichage des détails de ce message d'erreur spécifique sur les ordinateurs distants, créez une balise <customErrors> dans un fichier de configuration "web.config" situé dans le répertoire racine de l'application Web en cours. Attribuez ensuite la valeur "off" à l'attribut "mode" de cette balise <customErrors>.
    <!-- Fichier de configuration Web.Config -->
    <configuration>
    <system.web>
    <customErrors mode="Off"/>
    </system.web>
    </configuration>
    Remarques: La page d'erreurs actuellement affichée peut être remplacée par une page d'erreurs personnalisée. Pour ce faire, modifiez l'attribut "defaultRedirect" de la balise de configuration <customErrors> de l'application, de sorte qu'il pointe vers une URL de la page d'erreurs personnalisée.
    <!-- Fichier de configuration Web.Config -->
    <configuration>
    <system.web>
    <customErrors mode="RemoteOnly" defaultRedirect="mycustompage.htm"/>
    </system.web>
    </configuration>
    I believe it is a timeout problem. Any idea how work around this?
    Thanks,

    I don't have the right to create reports. With those datas, I need grouping them filtering them, commenting them, creating TCD and distributing it. I believe it is easier exporting it and handle it. Also I don't want the data changing from day to day.
    Then you are foobar'ed.
    there is nothing more you can do it the SSRS export feature is not working for you, and you don't have access to the CM12 db and you can't create report. There are no other option to access the data.
    Garth Jones | My blogs: Enhansoft and
    Old Blog site | Twitter:
    @GarthMJ

  • How to avoid line break ( br ) while exporting Interactive report in Excel

    Hi,
    I have a Interative report and I am using Apex download format as CSV.
    I have defined some of the column heading in multiple line using break < br >
    when I export this into the excel sheet..the column heading contains break also..
    - Any idea how to avoid line break while exporting in excel.
    - also how to put the columns heading in BOLD when exported in excel.
    Thanks,
    Deepak

    Hi Jari,
    I tried this but still getting the
    <br>Interactive Report
    Column Attributes Heading - Employee<br>Detail AddressWhen I download the Report in CSV Format
    I am getting the heading with <br>.
    I am looking for heading as - Employee Detail Address // with no <br> tagThanks,
    Deepak

  • VA05 report exectution  Excel format few line items gets automatically skip

    Dear,
    SAP support Team & Other team Members On SDN.
    As we are generating report from VA05 screen for retail sales order list, the report shows full required data but when the report is executed in Excel format few line items gets automatically skipped & further tried generated in TXT format the whole report get properly dragged.
    This problem is only in PRD Server, when i am teting the same in DEV Server it is properly Generated in EXCEL with Proper LINE ITEMS.
    Please kindly provide me with some Solution regarding the same.
    Warm Regards,
    Mohammed Hassan Naveed
    Deputy SAP Basis Consultant

    Hi,
    Have you tried using VA05N?

  • Exporting PDF document to Excel.  When I export a PDF document to Excel containing lists of  people the Excel page shows all the names on  one line several inches deep instead of on separate lines which makes editing impossible.  What am I doing wrong?

    Exporting PDF document to Excel.  When I export a PDF document to Excel containing lists of  people the Excel page shows all the names on  one line several inches deep instead of on separate lines which makes editing impossible.  What am I doing wrong?

    Murray is right. Padding (and margins) is added to the width. However, when using percentages, you should never use figures that add up to exactly 100%.
    Browsers need to convert the percentages to pixels. Because pixels must be whole numbers, some percentages are rounded up, which results in the final element dropping down below its neighbours. With percentages, it's much safer to use values that add up to 98% (99% often works, but 98% is safer).

  • Export customers line item clearing

    Hi all supporters,
    When am going to clear the export customers invoice in local currency on current date,it gives me the inv.foreing curr.amt as per current exchange rate,
    but i want the base exchange rate i.e.the rate by which the inv.is made.
    can any one help me.
    Prashant.

    Hi,
    No it is not for line item clearing. Expenses are line item GLs that gets closed to retained earning account at the year end activity. F.13 is used for Gls which are maintained on open item management or both and have an assigment field or any other in which same data is generated for a single debit and its credit ,just like GrIR clearing accounts.
    Hope it will help.
    Regards

  • How to export more than 5000 SharePoint items to excel?

    Need a solution on how to export more than 5000 share point items to excel file.

    Hello Chitra,
    Option
    suggested by soni is valid you can increase threshold limit through CA as well
    as you can disable list threshold using PowerShell.
    $web =Get-SPWeb
    "URL"
    $list =$web.Lists[“BIG_LIST_NAME”]
    $list.EnableThrottling= $false
    But disabling threshold cause performance issue, so as per best practices manage threshold limit according to your requirements
    from CA.

  • Is there a receipt scanner that works with the macbook pro that imports line items into numbers or excel?

    Is there a receipt scanner that works well with the MacBook Pro that imports line items into Numbers or Excel?  Thanks.

    Yes. Google...

  • Line item is not getting saved automatically

    Hi experts,
                     I have written below bdc program for Tcode cs01.
    REPORT ZM_BDC_CSO1
           NO STANDARD PAGE HEADING LINE-SIZE 255.
    TYPE-POOLS: TRUXS.
    TYPE-POOLS: SLIS.
    CONSTANTS C_X(1) TYPE C VALUE 'X'.
    DATA: GT_HEADERT  TYPE SLIS_T_LISTHEADER,
          GS_HEADERT TYPE SLIS_LISTHEADER.
    DATA : FNAME TYPE STRING.
    DATA : WLV_FILE TYPE RLGRAP-FILENAME.
    *DATA : WT_TEST LIKE ALSMEX_TABLINE OCCURS 0 WITH HEADER LINE.
    DATA : T_INTERN TYPE STANDARD TABLE OF ALSMEX_TABLINE,
           W_INTERN TYPE ALSMEX_TABLINE.
    TYPES : BEGIN OF X_MAT,
                 MATNR(18) TYPE C,
                 PLANT(4) TYPE C,
                 BOM_USAGE TYPE STLAN,
            END OF X_MAT.
    TYPES : BEGIN OF X_BOM,
                 MATNR1(18) TYPE C,
                 ITM_NO(4) TYPE C,
                 ITM_CAT(1) TYPE C,
                 BOM_COMP(18) TYPE C,
                 QTY(18) TYPE C,
            END OF X_BOM.
    DATA : T_MAT TYPE STANDARD TABLE OF X_MAT,
           W_MAT TYPE X_MAT.
    DATA : T_BOM TYPE STANDARD TABLE OF X_BOM,
           W_BOM TYPE X_BOM.
    DATA :   FNAM(30) TYPE C.
    DATA :  CNT TYPE STRING,
            VAR(2) TYPE C .
    DATA : INI TYPE C VALUE '0' .
    DATA: NEW_MARK TYPE BDCDATA-FNAM.
    DATA: COUNTER TYPE I.
    DATA : ITEM_NO(4) TYPE N.
    DATA :  IDXL TYPE SY-TABIX.
    DATA : GV_PFILE TYPE STRING.
    DATA : GV_RAW TYPE TRUXS_T_TEXT_DATA.
    DATA : GV_FILE TYPE RLGRAP-FILENAME,
           GV_FLAG(1) TYPE C.
    DATA : GW_BDCDATA  TYPE BDCDATA,
           GT_BDCDATA  TYPE STANDARD TABLE OF BDCDATA.
    DATA: GS_RETURN TYPE YV_MESSAGES,
          GT_RETURN TYPE STANDARD TABLE OF YV_MESSAGES.
    DATA: GV_MTEXT TYPE STRING.
    DATA: GW_FIELDCAT        TYPE SLIS_FIELDCAT_ALV,
          GT_HEADERFIELDCAT  TYPE SLIS_T_FIELDCAT_ALV.
    SELECTION-SCREEN : BEGIN OF BLOCK B1 WITH FRAME TITLE TEXT-001.
    PARAMETERS : P_PATH TYPE RLGRAP-FILENAME,
                 P_MODE TYPE CTU_PARAMS-DISMODE DEFAULT 'A'.
    SELECTION-SCREEN: END OF BLOCK B1.
    AT SELECTION-SCREEN ON VALUE-REQUEST FOR P_PATH.
      CALL FUNCTION 'F4_FILENAME'
       EXPORTING
         PROGRAM_NAME        = SYST-CPROG
      DYNPRO_NUMBER       = SYST-DYNNR
      FIELD_NAME          = ' '
       IMPORTING
         FILE_NAME           = P_PATH .
    INITIALIZATION.
      REFRESH: T_MAT, T_BOM,T_INTERN.
      CLEAR: W_MAT,W_BOM,W_INTERN,IDN,FLAG.
    *DATA :  T_INTERN TYPE STANDARD TABLE OF ALSMEX_TABLINE.
    START-OF-SELECTION.
      PERFORM UPLOAD_FILES.
      PERFORM BOM_UPLOAD.
      PERFORM ITEM_DATA.
      PERFORM DISPLAY_LOG.
    *&      Form  BOM_UPLOAD
          text
    -->  p1        text
    <--  p2        text
    FORM BOM_UPLOAD.
      SORT T_INTERN BY ROW COL.
      LOOP AT T_INTERN INTO W_INTERN.
        CASE W_INTERN-COL.
          WHEN 1.
            W_MAT-MATNR = W_INTERN-VALUE.
            W_BOM-MATNR1 = W_INTERN-VALUE.
          WHEN 2.
        W_BOM-PLANT = W_INTERN-VALUE.
            W_MAT-PLANT = W_INTERN-VALUE.
          WHEN 3.
        W_BOM-BOM_USAGE = W_INTERN-VALUE.
            W_MAT-BOM_USAGE = W_INTERN-VALUE.
          WHEN 4.
            W_BOM-ITM_NO = W_INTERN-VALUE.
          WHEN 5.
            W_BOM-ITM_CAT = W_INTERN-VALUE.
          WHEN 6.
            W_BOM-BOM_COMP = W_INTERN-VALUE.
          WHEN 7.
            W_BOM-QTY = W_INTERN-VALUE.
        ENDCASE.
        AT END OF ROW.
          APPEND W_BOM TO T_BOM.
          APPEND W_MAT TO T_MAT.
          CLEAR : W_BOM, W_MAT.
        ENDAT.
      ENDLOOP.
    ENDFORM.                    " BOM_UPLOAD
    *&      Form  ITEM_DATA
          text
    -->  p1        text
    <--  p2        text
    FORM ITEM_DATA.
      DATA : INT TYPE I.
      DELETE ADJACENT DUPLICATES FROM T_MAT COMPARING MATNR.
      SORT T_MAT BY MATNR. "HEADER DATA
      SORT T_BOM BY MATNR1. "ITEM DATA
    *CLEAR : COUNTER, ITEM_NO.
    *break naresh.
      LOOP AT T_MAT INTO W_MAT.
        REFRESH GT_BDCDATA.
        CLEAR   GW_BDCDATA.
        PERFORM HEADER_DETAILS.
        LOOP AT T_BOM INTO W_BOM WHERE MATNR1 = W_MAT-MATNR.
          CNT = CNT + 1.
          if CNT LE 9.
          CONCATENATE  '0' CNT INTO VAR.
          ELSE.
          VAR = CNT.
          ENDIF.
          ADD 1 TO COUNTER.
          ITEM_NO = 10 * COUNTER.
          OVERLAY ITEM_NO WITH '0000'.
          W_BOM-ITM_NO = ITEM_NO.
          PERFORM ITEMSET1.
          CLEAR VAR.
          PERFORM SCREEN1.
        ENDLOOP.
        CLEAR V_CNT.
        PERFORM SCREEN_DATA.
      ENDLOOP.
    ENDFORM.                    " ITEM_DATA
    *&      Form  HEADER_DETAILS
          text
    -->  p1        text
    <--  p2        text
    FORM HEADER_DETAILS.
      PERFORM BDC_DYNPRO      USING 'SAPLCSDI' '0100'.
      PERFORM BDC_FIELD       USING 'BDC_CURSOR'
                                    'RC29N-STLAN'.
      PERFORM BDC_FIELD       USING 'BDC_OKCODE'
                                    '/00'.
      PERFORM BDC_FIELD       USING 'RC29N-MATNR' W_MAT-MATNR.
                                 'lejn44001'.
      PERFORM BDC_FIELD       USING 'RC29N-WERKS' W_MAT-PLANT.
                                 '4600'.
    PERFORM BDC_FIELD       USING 'RC29N-STLAN' W_MAT-BOM_USAGE.
                                 '1'.
    PERFORM BDC_FIELD       USING 'RC29N-STLAN' '1'."W_MAT-BOM_USAGE.
                                 '1'.
    *perform bdc_field       using 'RC29N-DATUV'
                                 '22.06.2010'.
      PERFORM BDC_DYNPRO      USING 'SAPLCSDI' '0110'.
      PERFORM BDC_FIELD       USING 'BDC_OKCODE'
                                    '/00'.
      PERFORM BDC_FIELD       USING 'RC29K-BMENG'
                                    '1'.
      PERFORM BDC_FIELD       USING 'RC29K-STLST'
                                    '1'.
      PERFORM BDC_FIELD       USING 'BDC_CURSOR'
                                    'RC29K-EXSTL'.
      PERFORM BDC_DYNPRO      USING 'SAPLCSDI' '0111'.
      PERFORM BDC_FIELD       USING 'BDC_CURSOR'
                                    'RC29K-LABOR'.
      PERFORM BDC_FIELD       USING 'BDC_OKCODE'
                                    '/00'.
    ENDFORM.                    " HEADER_DETAILS
    FORM UPLOAD_FILES.
      CALL FUNCTION 'ALSM_EXCEL_TO_INTERNAL_TABLE'
        EXPORTING
          FILENAME                      = P_PATH
          I_BEGIN_COL                   = 1
          I_BEGIN_ROW                   = 2
          I_END_COL                     = 7
          I_END_ROW                     = 100
        TABLES
          INTERN                        = T_INTERN
    EXCEPTIONS
      INCONSISTENT_PARAMETERS       = 1
      UPLOAD_OLE                    = 2
      OTHERS                        = 3
      IF SY-SUBRC <> 0.
        WRITE 'Path of Excel file is not correct'.
        EXIT.
      ENDIF.
    ENDFORM.                    " UPLOAD_FILES
    FORM DISPLAY_LOG.
      DATA: LV_LAYOUT TYPE SLIS_LAYOUT_ALV.
    Design the layout
      LV_LAYOUT-ZEBRA = C_X. " alternative coloured lines
      LV_LAYOUT-COLWIDTH_OPTIMIZE = C_X. " Optimized column width
    Delete all warning messages
    DELETE IT_return WHERE Mtype = 'W' or Mtype = 'I'.
    Build Field Catalog
      PERFORM BUILD_FIELD_CATALOG.
    Display Log details
      CALL FUNCTION 'REUSE_ALV_GRID_DISPLAY'
           EXPORTING
                I_CALLBACK_PROGRAM     = SY-CPROG
                I_CALLBACK_TOP_OF_PAGE = 'TOP_OF_PAGE'
                IS_LAYOUT              = LV_LAYOUT
                IT_FIELDCAT            = GT_HEADERFIELDCAT[]
           TABLES
                T_OUTTAB               = GT_RETURN[]
           EXCEPTIONS
                PROGRAM_ERROR          = 1
                OTHERS                 = 2.
      IF SY-SUBRC <> 0.
        MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
                WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
      ENDIF. "SY-SUBRC <> 0.
      REFRESH GT_HEADERT.
      CLEAR   GS_HEADERT.
    ENDFORM.                    " DISPLAY_LOG
    FORM BUILD_FIELD_CATALOG.
    ENDFORM.                    " BUILD_FIELD_CATALOG
    FORM BDC_DYNPRO USING PROGRAM TYPE SY-REPID DYNPRO TYPE SY-DYNNR.
      CLEAR GW_BDCDATA.
      GW_BDCDATA-PROGRAM  = PROGRAM.
      GW_BDCDATA-DYNPRO   = DYNPRO.
      GW_BDCDATA-DYNBEGIN = 'X'.
      APPEND GW_BDCDATA TO GT_BDCDATA.
    ENDFORM.                    "BDC_DYNPRO
           Insert field                                                  *
    FORM BDC_FIELD USING FNAM TYPE ANY FVAL TYPE ANY.
      IF FVAL <> ''.
        CLEAR GW_BDCDATA.
        GW_BDCDATA-FNAM = FNAM.
        GW_BDCDATA-FVAL = FVAL.
        APPEND GW_BDCDATA TO GT_BDCDATA.
      ENDIF.
    ENDFORM.                    "BDC_FIELD
    FORM ITEMSET1.
    *cnt = '(01)'.
    *************commented******************
      PERFORM BDC_DYNPRO      USING 'SAPLCSDI' '0140'.
      PERFORM BDC_FIELD       USING 'BDC_CURSOR'
                                    'RC29P-POSTP(03)'.
      PERFORM BDC_FIELD       USING 'BDC_OKCODE'
                                    '/00'.
    **********28.06.2010**********************
      CONCATENATE 'RC29P-IDNRK(' VAR ')' INTO NEW_MARK.
      PERFORM BDC_FIELD USING NEW_MARK W_BOM-BOM_COMP.
      CLEAR NEW_MARK.
    *perform bdc_field       using 'RC29P-IDNRK(cnt)' W_BOM-BOM_COMP.
                                 'purchasecost'.
    *perform bdc_field       using 'RC29P-MENGE(01)' W_BOM-QTY.
                                 '20'.
      CONCATENATE 'RC29P-MENGE(' VAR ')' INTO NEW_MARK.
      PERFORM BDC_FIELD USING NEW_MARK W_BOM-QTY.
      CLEAR NEW_MARK.
    *perform bdc_field       using 'RC29P-POSTP(VAR)' W_BOM-ITM_CAT.
                                 'Z'.
      CONCATENATE 'RC29P-POSTP(' VAR ')' INTO NEW_MARK.
      PERFORM BDC_FIELD USING NEW_MARK W_BOM-ITM_CAT.
      CLEAR NEW_MARK.
    ********************************28.06.2010************
    *perform bdc_dynpro      using 'SAPLCSDI' '0130'.
    *perform bdc_field       using 'BDC_OKCODE'
                                 '/00'.
    *perform bdc_field       using 'BDC_CURSOR'
                                 'RC29P-POSNR'.
    *perform bdc_field       using 'RC29P-POSNR' W_BOM-ITM_NO.
                                 '0010'.
    *perform bdc_dynpro      using 'SAPLCSDI' '0131'.
    *perform bdc_field       using 'BDC_OKCODE'
                                 '/00'.
    *perform bdc_field       using 'BDC_CURSOR'
                                 'RC29P-POTX1'.
    *perform bdc_field       using 'RC29P-SANKA'
                                 'X'.
    *perform bdc_dynpro      using 'SAPLCSDI' '0140'.
    *perform bdc_field       using 'BDC_CURSOR'
                                 'RC29P-POSNR(01)'.
    *perform bdc_field       using 'BDC_OKCODE'
                                 '=FCBU'.
    ENDFORM.                                                    " itemset1
    *&      Form  screen_data
          text
    -->  p1        text
    <--  p2        text
    FORM SCREEN_DATA.
      CALL TRANSACTION 'CS01'  USING GT_BDCDATA  MODE  P_MODE UPDATE  'S'
                                         MESSAGES INTO GT_MESSAGES .
    ENDFORM.                    " screen_data
    *&      Form  SCREEN1
          text
    -->  p1        text
    <--  p2        text
    FORM SCREEN1.
      PERFORM BDC_DYNPRO      USING 'SAPLCSDI' '0130'.
      PERFORM BDC_FIELD       USING 'BDC_OKCODE'
                                    '/00'.
      PERFORM BDC_FIELD       USING 'BDC_CURSOR'
                                    'RC29P-POSNR'.
      PERFORM BDC_FIELD       USING 'RC29P-POSNR' W_BOM-ITM_NO.
                                 '0010'.
      PERFORM BDC_FIELD       USING 'RC29P-IDNRK' W_BOM-BOM_COMP.
                                 'PURCHASECOST'.
      PERFORM BDC_FIELD       USING 'RC29P-MENGE' W_BOM-QTY.
                                 '20'.
      PERFORM BDC_FIELD       USING 'RC29P-MEINS'
                                    'M'.
      PERFORM BDC_DYNPRO      USING 'SAPLCSDI' '0131'.
      PERFORM BDC_FIELD       USING 'BDC_OKCODE'
                                    '/00'.
      PERFORM BDC_FIELD       USING 'BDC_CURSOR'
                                    'RC29P-POTX1'.
      PERFORM BDC_FIELD       USING 'RC29P-SANKA'
                                    'X'.
    ENDFORM.                                                    " SCREEN1
    evrything is working fine. but after processing the line items for one material no. i need to save it manually then it goes back to initial screen and process takes place for the subsequesnt material no.
    e.g
    Material             BOM component   QUANTITY
    LEJN2689     PURCHASECOST     500
    LEJN2689     SOURCINGCOST     
    LEJN2689     INVRESERVE     
    LEJN2690     PURCHASECOST     600
    LEJN2690     SOURCINGCOST     
    LEJN2690     INVRESERVE     
    the above is the file type i am providing.
    for material LEJN2689 the component and quantity is uploaded but i have to click on 'save' button manuaaly then cursor goes back to initial screen for material LEJN2690.
    plz help.
    Regards,
    Ashmita Singh

    solved it!!!

  • MR11 diferrence in total and sum value of line items

    Hello
    MR11 was run and it was exported to excel - it is found that there is a difference in value between the total figure given under the indivudual  lines and the amount got by adding all the line items of the difference values. Can somebody please explain why this happens
    The total figure matched with another report taken outside SAP

    Export to word

  • Export the Report in Excel format

    Hi,
    How to export the Report in Excel format directly from the SAP to my Desktop.
    Plz. give me the process???
    Thanks

    use this,
    INCLUDE OLE2INCL.
    INCLUDE EXCEL__C.
    AND
             H_EXCEL TYPE OLE2_OBJECT,        " Excel object
              H_MAPL  TYPE OLE2_OBJECT,         " list of workbooks
              H_MAP   TYPE OLE2_OBJECT,          " workbook
              H_ZL    TYPE OLE2_OBJECT,           " cell
              H_F     TYPE OLE2_OBJECT,            " font
              H       TYPE I.
    AND
      PERFORM SUB_GET_DATA.
         'get data here
      PERFORM SUB_POP_DATA.
         'populate data here
    AND
      PERFORM SUB_DISP_EXCEL.
    *&      Form  SUB_DISP_EXCEL
    FORM SUB_DISP_EXCEL.
       START EXCEL
      CREATE OBJECT H_EXCEL 'EXCEL.APPLICATION'.
    SET PROPERTY OF H_EXCEL  'Visible' = 1.    " for printing o/p line by line in excel sheet
    get list of workbooks, initially empty
      CALL METHOD OF H_EXCEL 'Workbooks' = H_MAPL.
    add a new workbook
      CALL METHOD OF H_MAPL 'Add' = H_MAP.
    output column headings to active Excel sheet
      PERFORM FILL_CELL USING 1  1 1   10  'Mat Doc Number'(001) 'R'.
      PERFORM FILL_CELL USING 1  2 1    4  'Item'(002) 'R'.
      PERFORM FILL_CELL USING 1  3 1   10  'Mat Doc Date'(003) 'R'.
      PERFORM FILL_CELL USING 1  4 1   10  'Vendor'(004) 'R'.
      PERFORM FILL_CELL USING 1  5 1   20  'Mat Doc Item amount'(005) 'R'.
      PERFORM FILL_CELL USING 1  6 1   15  'Material price'(006) 'R'.
      PERFORM FILL_CELL USING 1  7 1    4  'Currency'(007) 'R'.
      PERFORM FILL_CELL USING 1  8 1   18  'Material'(008) 'R'.
      PERFORM FILL_CELL USING 1  9 1   30  'Material Desc'(009) 'R'.
      PERFORM FILL_CELL USING 1 10 1   19  'Qty in Unit of Entry'(010) 'R'.
      PERFORM FILL_CELL USING 1 11 1   19  'Qty Received'(011) 'R'.
      PERFORM FILL_CELL USING 1 12 1    4  'Unit of Entry'(012) 'R'.
      PERFORM FILL_CELL USING 1 13 1   20  'Mat Group'(013) 'R'.
      PERFORM FILL_CELL USING 1 14 1   16  'Vendor Invoice'(016) 'C'.
      LOOP AT T_OUT INTO W_OUT.
    copy flights to active EXCEL sheet
        H = SY-TABIX + 1.
        PERFORM FILL_CELL USING H  1 0 10 W_OUT-MBLNR 'R'.
        PERFORM FILL_CELL USING H  2 0  4 W_OUT-ZEILE 'R'.
        PERFORM FILL_CELL USING H  3 0 10 W_OUT-BLDAT 'R'.
        PERFORM FILL_CELL USING H  4 0 10 W_OUT-LIFNR 'R'.
        PERFORM FILL_CELL USING H  5 0 20 W_OUT-DMBTR 'R'.
        PERFORM FILL_CELL USING H  6 0 15 W_OUT-NETPR 'R'.
        PERFORM FILL_CELL USING H  7 0  4 W_OUT-WAERS1 'R'.
        PERFORM FILL_CELL USING H  8 0 18 W_OUT-MATNR 'R'.
        PERFORM FILL_CELL USING H  9 0 30 W_OUT-MAKTX 'R'.
        PERFORM FILL_CELL USING H 10 0 19 W_OUT-ERFMG 'R'.
        PERFORM FILL_CELL USING H 11 0 19 W_OUT-WEMNG 'R'.
        PERFORM FILL_CELL USING H 12 0  4 W_OUT-ERFME 'R'.
        PERFORM FILL_CELL USING H 13 0 20 W_OUT-WGBEZ 'R'.
        PERFORM FILL_CELL USING H 14 0 16 W_OUT-XBLNR 'C'.
        CLEAR W_OUT.
      ENDLOOP.
    CALL METHOD OF H_EXCEL 'Workbooks' = H_MAPL.
      CALL METHOD OF H_EXCEL 'Worksheets' = H_MAPL." EXPORTIN    G #1 = 2.
      SET PROPERTY OF H_EXCEL  'Visible' = 1.
      PERFORM ERR_HDL USING 'Unable to create workbook'.
    add a new workbook
    CALL METHOD OF H_MAPL 'Add' = H_MAP  EXPORTING #1 = 2. "----------can remove-------THIS IS FOR STAY AT LIST
      PERFORM ERR_HDL USING 'Unable to create new workbook'..
      FREE OBJECT H_EXCEL.
      PERFORM ERR_HDL USING 'Unable to free workbook'.
    ENDFORM.                    " SUB_DISP_EXCEL
          FORM FILL_CELL                                                *
          sets cell at coordinates i,j to value val boldtype bold       *
    FORM FILL_CELL USING I J BOLD COL VAL I_HORIZON_ALIGN.
      CALL METHOD OF H_EXCEL 'Cells' = H_ZL EXPORTING #1 = I #2 = J.
      PERFORM ERR_HDL USING 'set cell object error'.
      SET PROPERTY OF H_ZL 'Value' = VAL .
      PERFORM ERR_HDL USING 'set value  object error'.
      GET PROPERTY OF H_ZL 'Font' = H_F.
      PERFORM ERR_HDL USING 'set font  object error'.
      SET PROPERTY OF H_F 'Bold' = BOLD .
      PERFORM ERR_HDL USING 'set bold  object error'..
      SET PROPERTY OF H_ZL 'ColumnWidth' = COL.
      PERFORM ERR_HDL USING 'set columnwidth object error'.
      IF NOT I_HORIZON_ALIGN IS INITIAL.
      IF I_HORIZON_ALIGN = 'L'.
      SET PROPERTY OF H_ZL 'HorizontalAlignment' = XLLEFT.
      ELSEIF I_HORIZON_ALIGN = 'R'.
      SET PROPERTY OF H_ZL 'HorizontalAlignment' = XLRIGHT.
      ELSEIF I_HORIZON_ALIGN = 'C'.
      SET PROPERTY OF H_ZL 'HorizontalAlignment' = XLCENTER.
      ENDIF.
      ENDIF.
      PERFORM ERR_HDL USING 'set Alignment object error'.
    ENDFORM.                    "FILL_CELL
    *&      Form  ERR_HDL
          outputs OLE error if any                                       *
    -->  p1        text
    <--  p2        text
    FORM ERR_HDL USING VAL.
      IF SY-SUBRC <> 0.
        WRITE: / VAL.
        STOP.
      ENDIF.
    ENDFORM.                    " ERR_HDL

  • OBIEE Report Export from Dashboard to Excel doesn't suppress the columns as

    OBIEE Report Export from Dashboard to Excel doesn't suppress the columns as expected even after the properties are set to Suppress in the report. In Dashboard it is suppressed Properly but in the excel export it is not suppressed and values for the columns are repeated.
    Added the following to the instanceconfig :
    <Download>
    <Export xsi:type="excel">
    <DataValue>UseFormattedValue</DataValue>
    <RepeatRows>false</RepeatRows>
    </Export>
    </Download>
    But then could not restart services.The following error occured :
    Util Logger] Exception occurred:
         Severity:1
         Type:PKN3saw9ExceptionE
         File:saxreader.cpp
         Line:681
         Message:Sax parser returned an exception.
    Message: The prefix 'xsi' has not been mapped to any URI, Entity publicId: /oracle/ofm/instances/instance1/config/OracleBIPresentationServicesComponent/coreapplication_obips1/instanceconfig.xml, Entity systemId: , Line number: 43, Column number: 26
    Edited by: 887111 on Mar 27, 2013 11:23 PM

    Problem solved!!
    <br><br>
    See this part of the query:
    <br><br>
    if :P15_GESTOR_PROPIETARI='-3' then<br>
    w:= w||' AND (("STASVWREPORT_TASQUES"."GES_GES_ID"=:GESTOR ';<br>
    w:= w||'OR "STASVWREPORT_TASQUES"."GES_GES_ID_ESTA_ASSIGNADA"=:GESTOR)';<br>
    w:= w||'OR ("STASVWREPORT_TASQUES"."AGR_***_***_ID"=<FONT color=red>:P15_CANVI_DE_CLUB</FONT> ';
    w:= w||' AND "STASVWREPORT_TASQUES"."PUBLICA"=''S''))';<br>
    end if;<br>
    <br>
    when instead of :P15_CANVI_DE_CLUB I put a value (say ''EE'') it works correctly, finally I created an application item (ASSOCIAT) and when when I change :P15_CANVI_DE_CLUB I set :ASSOCIAT to the same value and the query is based on this application item:
    <br><br>
    if :P15_GESTOR_PROPIETARI='-3' then<br>
    w:= w||' AND (("STASVWREPORT_TASQUES"."GES_GES_ID"=:GESTOR ';<br>
    w:= w||'OR "STASVWREPORT_TASQUES"."GES_GES_ID_ESTA_ASSIGNADA"=:GESTOR)';<br>
    w:= w||'OR ("STASVWREPORT_TASQUES"."AGR_***_***_ID"=<FONT color=red>:ASSOCIAT </FONT>';<br>
    w:= w||' AND "STASVWREPORT_TASQUES"."PUBLICA"=''S''))';<br>
    end if;<br>
    <br>

  • Problem in uploading multiple line items while Creating sales order by BAPI

    Hi experts ,  Im able to create sales order  with one item while using this program, but the problem is  when iam having multiple  items or multiple sales order  , iam not able to createthe line items , though its creating  sales order header , Iam copy pasting my code , please add the additional code to my code to take more than 1 line items ,This is urgent requirement . Points will be rewarded for answers , Thanks in advance
    *& Report  Z_SO_CREATE_BAPI
    REPORT  Z_SO_CREATE_BAPI.
    DATA: i_header TYPE bapisdhd1 occurs 0 with header line.
    DATA: i_details TYPE bapisditm OCCURS 0 WITH HEADER LINE.
    DATA: i_partner TYPE bapiparnr OCCURS 0 WITH HEADER LINE.
    DATA: i_return1 TYPE bapiret2 OCCURS 0 WITH HEADER LINE.
    DATA: i_return2 TYPE bapiret2.
    data : ORDER_HEADER_IN like BAPISDHD1.
    data : ORDER_ITEMS_IN like BAPISDITM occurs 0 with HEADER LINE .
    data : ORDER_ITEMS_INX Like BAPISDITMX occurs 0 with HEADER LINE .
    data : RETURN like BAPIRET2 occurs 0 with header line.
    data : ORDER_PARTNERS like BAPIPARNR occurs 0 with
    header line.
    DATA : ORDER_KEYS LIKE BAPISDKEY OCCURS 0 WITH HEADER
    LiNE.
    data : ORDER_SCHEDULES_IN like BAPISCHDL occurs 0 with
    header line.
    data : ORDER_SCHEDULES_INX like BAPISCHDLX occurs 0 with
    header line.
    data : BEGIN OF TAB OCCURS 0,
           SRNO(4),
            DOC_TYPE like ORDER_HEADER_IN-dOC_TYPE,
            SALES_ORG LIKE ORDER_HEADER_IN-SALES_ORG,
            DISTR_CHAN LIKE ORDER_HEADER_IN-DISTR_CHAN,
            DIVISION like ORDER_HEADER_IN-DIVISION,
           REQ_DATE_H(10),
           PURCH_DATE(10),
           PMNTTRMS LIKE ORDER_HEADER_IN-PMNTTRMS,
           PURCH_NO_C LIKE ORDER_HEADER_IN-PURCH_NO_C,
           ITM_NUMBER like BAPISDITM-ITM_NUMBER,
            MATERIAL   LIKE  ORDER_ITEMS_IN-MATERIAL ,
            PLANT LIKE ORDER_ITEMS_IN-PLANT,
           TARGET_QTY LIKE ORDER_ITEMS_IN-TARGET_QTY,
           ITM_NUMBERX like  ORDER_ITEMS_INX-ITM_NUMBER ,
           MATERIALX   LIKE  ORDER_ITEMS_INX-MATERIAL ,
           CUST_MAT22 LIKE ORDER_ITEMS_IN-CUST_MAT22,
           PLANTX LIKE ORDER_ITEMS_INX-PLANT,
           TARGET_QTYX LIKE ORDER_ITEMS_INX-TARGET_QTY,
           ITM_NUMBER LIKE ORDER_ITEMS_IN-ITM_NUMBER,
           MATERIAL   LIKE  ORDER_ITEMS_IN-MATERIAL ,
            PARTN_ROLE LIKE ORDER_PARTNERS-PARTN_ROLE,
            PARTN_NUMB LIKE ORDER_PARTNERS-PARTN_NUMB,
          END OF TAB.
    DATA: v_vbeln TYPE bapivbeln-vbeln.
    selection-screen begin of block b1 with frame.
    skip 3.
    parameter:p_infile like rlgrap-filename obligatory.
    skip 3.
    selection-screen end  of block b1.
    AT SELECTION-SCREEN ON VALUE-REQUEST FOR p_infile.
      PERFORM value_help.
    start-of-selection.
    CALL FUNCTION 'WS_UPLOAD'
      EXPORTING
        filename                     = p_infile
       FILETYPE                      = 'DAT'
      HAS_FIELD_SEPARATOR           = 'X'
      HEADER_LENGTH                 = 0
      READ_BY_LINE                  = 'X'
      DAT_MODE                      = ' '
      CODEPAGE                      = ' '
      IGNORE_CERR                   = ABAP_TRUE
      REPLACEMENT                   = '#'
      CHECK_BOM                     = ' '
      VIRUS_SCAN_PROFILE            =
      NO_AUTH_CHECK                 = ' '
    IMPORTING
      FILELENGTH                    =
      HEADER                        =
      tables
        data_tab                      = tab.
    EXCEPTIONS
      FILE_OPEN_ERROR               = 1
      FILE_READ_ERROR               = 2
      NO_BATCH                      = 3
      GUI_REFUSE_FILETRANSFER       = 4
      INVALID_TYPE                  = 5
      NO_AUTHORITY                  = 6
      UNKNOWN_ERROR                 = 7
      BAD_DATA_FORMAT               = 8
      HEADER_NOT_ALLOWED            = 9
      SEPARATOR_NOT_ALLOWED         = 10
      HEADER_TOO_LONG               = 11
      UNKNOWN_DP_ERROR              = 12
      ACCESS_DENIED                 = 13
      DP_OUT_OF_MEMORY              = 14
      DISK_FULL                     = 15
      DP_TIMEOUT                    = 16
      OTHERS                        = 17
    IF sy-subrc <> 0.
    MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
            WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
    ENDIF.
    **Validation for the Create SO screen
    *AT SELECTION-SCREEN ON BLOCK na_create.
    Loop at Tab.
    i_header-doc_type =  TAB-DOC_TYPE .
    i_header-sales_org = TAB-SALES_ORG.
    i_header-distr_chan = TAB-DISTR_CHAN .
    i_header-division = TAB-DIVISION .
    append i_header.
    *endloop.
    i_partner-partn_role = TAB-PARTN_ROLE .
    i_partner-partn_numb =  TAB-PARTN_NUMB.
    APPEND i_partner.
    i_details-material =  TAB-MATERIAL .
    APPEND i_details.
    endloop.
    *Bapi for Creating SO
                   CALL FUNCTION 'BAPI_SALESORDER_CREATEFROMDAT2'
                     EXPORTING
                     SALESDOCUMENTIN               = v_vbeln
                       order_header_in               = i_header
                     ORDER_HEADER_INX              =
                     SENDER                        =
                     BINARY_RELATIONSHIPTYPE       =
                     INT_NUMBER_ASSIGNMENT         =
                     BEHAVE_WHEN_ERROR             =
                     LOGIC_SWITCH                  =
                     TESTRUN                       =
                     CONVERT                       = ' '
                    IMPORTING
                      SALESDOCUMENT                 = v_vbeln
                     tables
                      RETURN                        = i_return1
                      ORDER_ITEMS_IN                = i_details
                      ORDER_ITEMS_INX               = ORDER_ITEMS_INX
                       order_partners                = i_partner .
                     ORDER_SCHEDULES_IN            =
                     ORDER_SCHEDULES_INX           =
                     ORDER_CONDITIONS_IN           =
                     ORDER_CONDITIONS_INX          =
                     ORDER_CFGS_REF                =
                     ORDER_CFGS_INST               =
                     ORDER_CFGS_PART_OF            =
                     ORDER_CFGS_VALUE              =
                     ORDER_CFGS_BLOB               =
                     ORDER_CFGS_VK                 =
                     ORDER_CFGS_REFINST            =
                     ORDER_CCARD                   =
                     ORDER_TEXT                    =
                     ORDER_KEYS                    =
                     EXTENSIONIN                   =
                     PARTNERADDRESSES              =
    IF NOT v_vbeln IS INITIAL.
    *Bapi Commit Work
    CALL FUNCTION 'BAPI_TRANSACTION_COMMIT'
    EXPORTING
    WAIT =
    IMPORTING
    return = i_return2
    ELSE.
    CALL FUNCTION 'BAPI_TRANSACTION_ROLLBACK'
    IMPORTING
    RETURN =
    ENDIF.
    LOOP AT i_return1 .  "INTO wa_return1.
    WRITE:/ i_return1-message.
    ENDLOOP.
    FORM value_help .
      CALL FUNCTION 'DSVAS_DOC_WS_FILENAME_GET_50'
        EXPORTING
          DEF_FILENAME     = ' '
          DEF_PATH         = ' '
          MASK             = ',.,..'
          MODE             = 'O'
          TITLE            = ' '
        IMPORTING
          FILENAME         = p_infile
        EXCEPTIONS
          INV_WINSYS       = 1
          NO_BATCH         = 2
          SELECTION_CANCEL = 3
          SELECTION_ERROR  = 4
          OTHERS           = 5.
      IF sy-subrc <> 0.
    MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
             WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
      ENDIF.
    endform.
    txt file data
    order type  salesorg   distch      divison       materialno                  parter role
    TA     PB01     01     00     000000000000000852     WE
    Partner no
    8101000000

    Hi Neerja,
    you can reffer this sample code. It may not be complet soluation for your poblem,
    but you will get some idea.
    *& Report  ZBAPI_SALESORDER_CREATE
    *& Author : Karthik
    REPORT  ZBAPI_SALESORDER_CREATE.
    data : ORDER_HEADER_IN like BAPISDHD1.
    data : ORDER_ITEMS_IN like BAPISDITM occurs 0 with
    header line.
    data : RETURN like BAPIRET2 occurs 0 with header line.
    data : ORDER_PARTNERS like BAPIPARNR occurs 0 with
    header line.
    DATA : ORDER_KEYS LIKE BAPISDKEY OCCURS 0 WITH HEADER
    LINE.
    data : ORDER_SCHEDULES_IN like BAPISCHDL occurs 0 with
    header line.
    data : BEGIN OF TAB OCCURS 0,
            SRNO(4),
            DOC_TYPE like ORDER_HEADER_IN-dOC_TYPE,
            SALES_ORG LIKE ORDER_HEADER_IN-SALES_ORG,
            DISTR_CHAN LIKE ORDER_HEADER_IN-DISTR_CHAN,
            DIVISION like ORDER_HEADER_IN-DIVISION,
           REQ_DATE_H(10),
            PURCH_DATE(10),
            PMNTTRMS LIKE ORDER_HEADER_IN-PMNTTRMS,
            PURCH_NO_C LIKE ORDER_HEADER_IN-PURCH_NO_C,
            ITM_NUMBER like BAPISDITM-ITM_NUMBER,
            CUST_MAT22 LIKE ORDER_ITEMS_IN-CUST_MAT22,
            PLANT LIKE ORDER_ITEMS_IN-PLANT,
            TARGET_QTY LIKE ORDER_ITEMS_IN-TARGET_QTY,
            PARTN_ROLE LIKE ORDER_PARTNERS-PARTN_ROLE,
            PARTN_NUMB LIKE ORDER_PARTNERS-PARTN_NUMB,
          END OF TAB.
    data: itab1 like alsmex_tabline occurs 0 with header
    line.
    DATA: gd_currentrow type i.
    data : PURCHASEORDER like ekko-ebeln.
    Data: tot_rec type i,     "Total Records
         gd_update type i,   "Main Table Increement Counter
         gd_lines type i,    "Success Table increement Counter
         w_textout like t100-text. "VARIABLE TO GET ERRORLOG
    data : begin of it_success occurs 0,
            SALESDOCUMENT LIKE BAPIVBELN-VBELN,  "PROJECT
          end of it_success.
    data : begin of it_error occurs 0,
            srno(4),
            err_msg(73) TYPE c,    "TO RETREIVE ERROR MESSAGES
         end of it_error.
    data : srno(4).
    DATA : SALESDOCUMENT LIKE  BAPIVBELN-VBELN.
    selection-screen begin of block b1 with frame.
    skip 3.
    parameter:p_infile like rlgrap-filename obligatory.
    skip 3.
    selection-screen end  of block b1.
    AT SELECTION-SCREEN ON VALUE-REQUEST FOR p_infile.
      PERFORM value_help.
    start-of-selection.
      call function 'ALSM_EXCEL_TO_INTERNAL_TABLE'
        EXPORTING
          filename                = p_infile
          i_begin_col             = '1'
          i_begin_row             = '2' "Do not require
    headings
          i_end_col               = '22'
          i_end_row               = '10000'
        TABLES
          intern                  = itab1
        EXCEPTIONS
          inconsistent_parameters = 1
          upload_ole              = 2
          others                  = 3.
      if sy-subrc <> 0.
        message e010(zz) with text-001. "Problem uploading
    Excel Spreadsheet
      endif.
    *perform open_group.
      sort itab1 by row col.
    Get first row retrieved
      read table itab1 index 1.
    Set first row retrieved to current row
      gd_currentrow = itab1-row.
      loop at itab1.
    Reset values for next row
        if itab1-row ne gd_currentrow.
          append tab .
          clear tab.
          gd_currentrow = itab1-row.
        endif.
        SHIFT ITAB1-VALUE LEFT DELETING LEADING SPACE.
        case itab1-col.
          when '0001'.
            TAB-SRNO = itab1-value.
          when '0002'.
            TAB-DOC_TYPE = itab1-value.
          when '0003'.
            TAB-SALES_ORG = itab1-value.
          when '0004'.
            TAB-DISTR_CHAN = itab1-value.
          when '0005'.
            TAB-DIVISION = itab1-value.
         when '0006'.
           TAB-REQ_DATE_H =  itab1-value.
          when '0006'.
            TAB-PURCH_DATE = itab1-value.
          when '0007'.
            TAB-PMNTTRMS = itab1-value.
          when '0008'.
            TAB-PURCH_NO_C = itab1-value.
            when '0009'.
            TAB-ITM_NUMBER = itab1-value.
           when '0010'.
            TAB-CUST_MAT22 = itab1-value.
          when '0011'.
            TAB-PLANT  = itab1-value.
          when '0012'.
            TAB-TARGET_QTY = itab1-value.
          when '0013'.
            TAB-PARTN_ROLE = itab1-value.
          when '0014'.
            TAB-PARTN_NUMB = itab1-value.
        endcase.
      endloop.
      append tab.
      clear tab.
      sort tab by SRNO.
      LOOP AT TAB.
       concatenate tab-REQ_DATE_H+4(4)
    tab-REQ_DATE_H2(2) tab-REQ_DATE_H0(2) into
    tab-REQ_DATE_H.
        concatenate tab-PURCH_DATE+4(4)
    tab-PURCH_DATE2(2) tab-PURCH_DATE0(2) into
    tab-PURCH_DATE.
        SRNO = TAB-SRNO.
        CALL FUNCTION 'CONVERSION_EXIT_ALPHA_INPUT'
          EXPORTING
            INPUT  = tab-PARTN_NUMB
          IMPORTING
            OUTPUT = tab-PARTN_NUMB.
        CALL FUNCTION 'CONVERSION_EXIT_ALPHA_INPUT'
          EXPORTING
            INPUT  = tab-CUST_MAT22
          IMPORTING
            OUTPUT = tab-CUST_MAT22.
        IF TAB-SRNO = SRNO.
          ORDER_HEADER_IN-DOC_TYPE = TAB-DOC_TYPE.
          ORDER_HEADER_IN-SALES_ORG = TAB-SALES_ORG.
          ORDER_HEADER_IN-DISTR_CHAN = TAB-DISTR_CHAN.
         ORDER_HEADER_IN-REQ_DATE_H = TAB-REQ_DATE_H.
          ORDER_HEADER_IN-PURCH_DATE = TAB-PURCH_DATE.
          ORDER_HEADER_IN-PMNTTRMS = TAB-PMNTTRMS.
          ORDER_HEADER_IN-PURCH_NO_C = TAB-PURCH_NO_C.
          ORDER_HEADER_IN-DIVISION  = tab-DIVISION.
          ORDER_ITEMS_IN-ITM_NUMBER = tab-ITM_NUMBER.
          ORDER_ITEMS_IN-material = TAB-CUST_MAT22.
          ORDER_ITEMS_IN-PLANT      = TAB-PLANT.
          APPEND ORDER_ITEMS_IN.
          ORDER_PARTNERS-PARTN_ROLE = TAB-PARTN_ROLE.
          ORDER_PARTNERS-PARTN_NUMB = TAB-PARTN_NUMB.
          APPEND ORDER_PARTNERS.
          ORDER_SCHEDULES_IN-ITM_NUMBER = tab-ITM_NUMBER.
          ORDER_SCHEDULES_IN-REQ_QTY = tab-TARGET_QTY.
          append ORDER_SCHEDULES_IN.
        ENDIF.
        AT END OF SRNO.
          CALL FUNCTION 'BAPI_SALESORDER_CREATEFROMDAT2'
            EXPORTING
               SALESDOCUMENTIN               =
                 ORDER_HEADER_IN               = ORDER_HEADER_IN
               ORDER_HEADER_INX              =
               SENDER                        =
               BINARY_RELATIONSHIPTYPE       =
               INT_NUMBER_ASSIGNMENT         =
               BEHAVE_WHEN_ERROR             =
               LOGIC_SWITCH                  =
               TESTRUN                       =
               CONVERT                       = ' '
           IMPORTING
             SALESDOCUMENT                 = SALESDOCUMENT
            TABLES
             RETURN                        = RETURN
                 ORDER_ITEMS_IN                = ORDER_ITEMS_IN
               ORDER_ITEMS_INX               =
                 ORDER_PARTNERS                = ORDER_PARTNERS
                 ORDER_SCHEDULES_IN            = ORDER_SCHEDULES_IN
               ORDER_SCHEDULES_INX           =
               ORDER_CONDITIONS_IN           =
               ORDER_CONDITIONS_INX          =
               ORDER_CFGS_REF                =
               ORDER_CFGS_INST               =
               ORDER_CFGS_PART_OF            =
               ORDER_CFGS_VALUE              =
               ORDER_CFGS_BLOB               =
               ORDER_CFGS_VK                 =
               ORDER_CFGS_REFINST            =
               ORDER_CCARD                   =
               ORDER_TEXT                    =
             ORDER_KEYS                    = ORDER_KEYS
               EXTENSIONIN                   =
               PARTNERADDRESSES              =
          IF SALESDOCUMENT <> SPACE.
            commit work.
            ADD 1 TO gd_update.
            it_success-SALESDOCUMENT = SALESDOCUMENT.
            append it_success.
            CLEAR :SALESDOCUMENT,ORDER_HEADER_IN.
            REFRESH : RETURN,ORDER_ITEMS_IN,ORDER_PARTNERS.
          ELSE.
            loop at return.
              it_error-SRNO = tab-SRNO.
              it_error-err_msg = return-MESSAGE .
              Append it_error.
            ENDLOOP.
            CLEAR :SALESDOCUMENT,ORDER_HEADER_IN.
            REFRESH : RETURN,ORDER_ITEMS_IN,ORDER_PARTNERS.
          ENDIF.
        endat.
      endloop.
      DESCRIBE TABLE it_success LINES gd_lines.
      IF gd_lines GT 0.
        Display result report column headings
        PERFORM display_column_headings.
        Display result report
        PERFORM DISPLAY_SUCESS.
      ENDIF.
    IF SUCESS FAILS Display Error Report
      DESCRIBE TABLE it_error LINES gd_lines.
      IF gd_lines GT 0.
        PERFORM errorheadings.
        PERFORM errorreport.
      ENDIF.
    *&      Form  display_column_headings
          text
    FORM display_column_headings.
      WRITE:2 ' Success Report '(014) COLOR COL_POSITIVE.
      SKIP.
      WRITE:2 'The following records inserted
    successfully:'(013).
      WRITE:/ sy-uline(15).
      FORMAT COLOR COL_HEADING.
      WRITE:/      sy-vline,
               (10) 'Sales order'(004), sy-vline.
      WRITE:/ sy-uline(15).
    ENDFORM.                    "display_column_headings
    *Subroutine to display SUCESS REPORT
    FORM DISPLAY_SUCESS.
      FORMAT COLOR COL_NORMAL.
      LOOP AT it_success.
        WRITE:/      sy-vline,
            (10)  it_success-SALESDOCUMENT, sy-vline.
        CLEAR it_success.
      ENDLOOP.
      WRITE:/ sy-uline(15).
      REFRESH: it_success.
      FORMAT COLOR COL_BACKGROUND.
    ENDFORM.                               "
    DISPLAY_REPORT
    *&      Form  errorreport
          text
    FORM errorreport.
      LOOP AT it_error.
        WRITE:/      sy-vline,
                (10) it_error-SRNO, sy-vline,
                 (40) it_error-err_msg, sy-vline.
      ENDLOOP.
      WRITE:/ sy-uline(104).
      REFRESH: it_error.
    endform.                    "errorreport
    *&      Form  ERRORHEADINGS
          text
    FORM ERRORHEADINGS.
      SKIP.
      WRITE:2 ' Error Report '(007) COLOR COL_NEGATIVE.
      SKIP.
      WRITE:2 'The following records failed during
    update:'(008).
      WRITE:/ sy-uline(104).
      FORMAT COLOR COL_HEADING.
      WRITE:/      sy-vline,
              (10) 'ERROR.'(009), sy-vline.
      WRITE:/ sy-uline(104).
      FORMAT COLOR COL_NORMAL.
    ENDFORM.                    "ERRORHEADINGS
    **&      Form  value_help
          text
    -->  p1        text
    <--  p2        text
    FORM value_help .
      CALL FUNCTION 'DSVAS_DOC_WS_FILENAME_GET_50'
        EXPORTING
          DEF_FILENAME     = ' '
          DEF_PATH         = ' '
          MASK             = ',.,..'
          MODE             = 'O'
          TITLE            = ' '
        IMPORTING
          FILENAME         = p_infile
        EXCEPTIONS
          INV_WINSYS       = 1
          NO_BATCH         = 2
          SELECTION_CANCEL = 3
          SELECTION_ERROR  = 4
          OTHERS           = 5.
      IF sy-subrc <> 0.
    MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
            WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
      ENDIF.
    endform.                    "value_help
    Regards,
    Amit.

Maybe you are looking for

  • MacBook won't detect Toshiba 1T external hard drive

    I just upgraded my operating system on my MacBook Pro and now my laptop won't detect my Toshiba 1T external hard drive, even though I've been using it before.  Any ideas?

  • Unpairing remote on mavericks osx

    Help! I have my Mac mini that acts as a file server for my Apple TV, however when I control my Apple TV using my Apple remote, it also controls my iTunes. I have opened up system preferences as all the forums say, gone into security and privacy in th

  • IPod NOT playing iTunes downloads - HELP!

    I thought it was an audiobook I downloaded, but I re-downloaded it tonight and it still didn't work. So I downloaded a song and just like the book, it went swiftly into iTunes and played fine. When I sync the iPod, the music comes over, but will NOT

  • OBIEE 11.1.1.7 and external OpenLDAP provider

    Hi, my organization recently decided to upgrade OBIEE from version 11.1.1.6 to 11.1.1.7. I've made installation on our DEV environment followed the instructions prepared during previous installation (11.1.1.6). The installation went without any probl

  • How can i use java with xml in netbean ide tell me step by step

    i am vivek kumar kanaujia from Kanpur