Is there any batch function module for '/SAPAPO/MSNP_GET_DRPIO_READ' in APO

Hi,
Iam developing a report for APO, wherein I pass matid & locid to the function module '/SAPAPO/MSNP_GET_DRPIO_READ' and get the order details as the o/p from the function module, now these takes place in a loop..endloop for more than 60,000 records which takes much of the processing time, can this be avoided by passing full table of matid,locid to the function module or rather a batch FM for the above mentioned function module.
Thanks & Regards,
Sanjay

HI,
Try using Function Module:
DD_DOMA_GET , If it is RFC enabled it can be used for reading the domain,
Kindlly go through this link below:
How to get "Fixed Domain Values" from other system by RFC-Call?
Hope it helps,
Regards
Mansi

Similar Messages

  • Any BAPI/Function Module for adding new record with dates in PA0027

    Hi all,
    I am tryig to find is there any BAPI/Function module for updating new record with Start Date and End date for specified Personal Number in PA0027 Table.
    In PA0027 table i will be passing start date and end date for selected personal number, it needs to add new record with this details in the table checking the condition that this start date and end dates should not be between any of of start date and end dates for the specified personal number.
    thanks for ur time.
    Murali

    Hi Raj/Suresh thanks for ur answers.
    but i am having a problem,i gave this values.
    INFTY               -
                0027
    NUMBER              -
                00000010
    SUBTYPE             -
                010
    OBJECTID
    LOCKINDICATOR
    VALIDITYEND         -
                03/12/2006
    VALIDITYBEGIN       -
                03/01/2006
    RECORDNUMBER        -
                000
    RECORD              -
                P0027
    OPERATION           -
                CHK
    TCLAS               -
                A
    DIALOG_MODE         -
                0
    NOCOMMIT            -
                Y
    VIEW_IDENTIFIER
    SECONDARY_RECORD
    i am getting short dump saying that
    The source field is too short.
    The current program, "SAPLHRMM", tried to assign a field to a field symbo
    However, the field is shorter than the type of the field symbol, which
    is not allowed.
    The statement in question is in the form ASSIGN f TO <fs> CASTING or
    ASSIGN f TO <fs> with a field symbol that was created using the
    STRUCTURE addition.
    I tried  operation - Chage,Create (same thing for all inputs)
    is this correct funtion moduel for my requirment?
    what ever i am passing the start and end dates this should check in the table records with this personal number and if this start date and end dates are not between of any start and end dates then it should add new record with this dates.
    Thanks for ur time.
    Murali.

  • Is there any RFC function module to read domain fixed value

    Hi,
    Is there any RFC function module to read domain fixed value from remote system in basis layer?
    As we cannot simply wrap DD_DOMVALUES_GET with a new RFC module,because remote system will not install our component, our wrap function module is not there.
    We may need a RFC fm from basis layer.

    HI,
    Try using Function Module:
    DD_DOMA_GET , If it is RFC enabled it can be used for reading the domain,
    Kindlly go through this link below:
    How to get "Fixed Domain Values" from other system by RFC-Call?
    Hope it helps,
    Regards
    Mansi

  • Are there BAPI or function modules for creating posting address ?

    Are there BAPI or function modules for creating posting address and budget address? We are currently use BDC program and T code FMBSPO_MULT (Posting address) and T code FMBSBO_MULT(budget address), but it is a very slow processing because we have thousands of funds centers.
    Your input will be appreciated!
    Regards,
    Fisher Li

    Li,
    You will have, may be more answers in the technical forum :
    https://www.sdn.sap.com/irj/sdn/collaboration
    Regards
    Valérie

  • Is there any standard function available for generation of RIN number.

    Hi experts,
    RIN is Renewable Identifiaction Number.
    Structure for a RIN is a 34-character numeric code in the format:
         YYYYCCCCFFFFFBBBBBRRDKSSSSSSEEEEEE
    YYYY  = Year of Batch Production (when it leaves the facility)
    CCCC = Company registration ID
    FFFFF = Facility registration ID
    BBBBB = Producer assigned Batch Number
    RR  = Equivalence Value for the renewable fuel
    D = Renewable Type Flag (1 - cellulosic; 2 - non-cellulosic)
    K = RIN Type Flag (1 - standard, 2 - extra-value)
    SSSSSS  = RIN Block Starting Gallon Number 
    EEEEEE  = RIN Block Ending Gallon Number 
    Is there any standard function avaiable in R3 to generate such number?
    Please reply asap.
    Thank you in advance.

    Hi deepak,
    1. we can use the FM
    DATE_CHECK_PLAUSIBILITY
    regards,
    amit m.

  • Is there any bapi/Function module to change only header text in fb02

    Hi ,
    I want to change only header text in FB02 .the header text will come  from a internal table.My Requirement is
    1. open a document in FB02
    2.change the header text of the document.
    Right now i'm doing this through an BDC.but i'm looking for a BAPI /FM.
    I Tried bapi_acc_gl_posting_post, fI_document_change..
    is there any BAPI/FM for this???
    Thanks,
    Challa

    You can use SAVE_TEXT FM
    Thanks
    Seshu

  • Is there Any Standard Function Module that populates mail in SAP inbox

    Hello Experts,
                         The scenario that we are working is , Email Integration in SOLMAN.That is the done using XI , first the mails  raised for  Support Desk issues from Outlook are read and collected in XI ,now the requirement is from XI we have to populate the mails into SOLMAN's Inbox. So is there any standard FM that can be used in XI for this purpose.
       Or is there any other way in which the mails can come into Solman's Inbox,If someone has worked on this , please give me your valuable suggestions ASAP.
    Thanks & Regards,
    Mohana

    Hi deepak,
    1. we can use the FM
    DATE_CHECK_PLAUSIBILITY
    regards,
    amit m.

  • BAPI Function Module for SCM APO Trans code /SAPAPO/AC42

    Hi,
       Is there any BAPI Function Modules for SCM APO Tcode /SAPAPO/AC42.
       This BAPI FM should return the column values "Remaining Prod Alloc"  and "Incoming Order Quantity" when we give
       below details as inputs for the Tcode /SAPAPO/AC42
            Product Allocation Group
            Product
            Allocation Procedure
            prod Alloc step
            Product Alloc Object (Characteristics of Product Alloc Group)
            Plant (Characteristics of Product Alloc Group)
            Customer Group 5 (Characteristics of Product Alloc Group)
        Reward points if helpful.
    Thanks,
    Mich

    Hi,
    You should be able to get the information using the standard BAPI (Assuming you are using SCM5.0) BAPI_APOPAL_INSERT in the transaction BAPI.
    ProductAllocationAPO.DataInsert
    Interface to Import Product Allocation Data  Functionality
    This method is used to adopt data from OLTP systems for product allocation in the global availability check.
    You can do the following using the method:
    Adopt new data
    You can adopt new characteristics combinations or new time series. Newly created characteristics combinations have the status Active and are therefore included in the product allocation check.
    Change existing data
    You can overwrite existing data if you have set the interface parameter ALLOW_UPDATE. You can set the status of existing characteristics combinations to Active if you set the interface parameter UPDATE_STATUS. If the characteristics combination does not exist, the system creates it.
    The product allocation quantity is overwritten for existing time series. If you also want to change the incoming orders quantity, you must set the interface parameter UPDATE_INCOMING_ORDER_QTY. If the time series does not exist, the system creates it.
    Prerequisite
    To be able to use this method, you must have made all the Customizing settings for product allocation. For more information, see the Implementation Guide (IMG) for SAP APO under Global Available-to-Promise -> Product Allocation.
    Regards
    Vinod

  • Function Module for open Purchase Order & Sales Order?

    Hi, commonly I read the data from tables and calculate the open quantity for sales order and purchase order, but I want to know, are there any standard function modules for getting the list of open "purchase order" and "sales order" respectively?
    Thanks and Regards.

    hi Ren,
    u can check all these bapi's related to salesorder
    BAPI_SALESORDER_CHANGE Sales order: Change Sales Order
    BAPI_SALESORDER_CONFIRMDELVRY Sales Order: Confirmation of Delivery; Document Flow Update
    BAPI_SALESORDER_CREATEFROMDAT1 Sales order: Create Sales Order
    BAPI_SALESORDER_CREATEFROMDAT2 Sales order: Create Sales Order
    BAPI_SALESORDER_CREATEFROMDATA Create Sales Order, No More Maintenance
    BAPI_SALESORDER_GETLIST Sales order: List of all Orders for Customer
    BAPI_SALESORDER_GETSTATUS Sales Order: Display Status
    BAPI_SALESORDER_SIMULATE Sales Order: Simulate Sales Order
    May be this FM can help you
    MB_ADD_PURCHASE_ORDER_QUANTITY (Reading and adding open purchase order quantities)
    Regards,
    Naveen

  • Function module for getting the all PO waiting for release

    Hi,
    Is there any standard Function module for gettting all the PO's which all waiting for release.
    Regards
    Bala.

    hi Bala,
    ECC 6.0 Exits for VA01
    go through the above link i think that will help u...
    Regards,
    sindhu.

  • Z function modules for OLE

    Hi all,
    Is there any Z function modules for OLE, which will download the data directly to Excel with 2 sheets.
    Regards,
    Shalini

    Hi Shalini Reddy
    there is no FM  but code is there... u can see...
    *& Report  YOLE_FOR_EXCEL
    REPORT  yole_for_excel.
    *REPORT ZTEST_BYW.
    OLE specific include file
    INCLUDE ole2incl.
    INCLUDE excel__c.
    data definitions of OLE objects with type ole2_object
    PARAMETERS: p_filenm(80) LOWER CASE OBLIGATORY
    DEFAULT 'd:\temp\report_tsl.xls'.
    DATA: g_tmp_workbook TYPE ole2_object.
    DATA: g_tmp_worksheets TYPE ole2_object.
    DATA: g_tmp_worksheet1 TYPE ole2_object.
    DATA: g_tmp_worksheet2 TYPE ole2_object.
    DATA: g_pc_template LIKE rcgfiletr-ftappl
    VALUE 'd:\temp\mmr_rpt_tsl_tmp.xls'.
    DATA: g_excel TYPE ole2_object.
    DATA: g_workbooks TYPE ole2_object.
    DATA: g_workbook TYPE ole2_object.
    DATA: g_worksheets TYPE ole2_object.
    DATA: g_worksheet TYPE ole2_object.
    DATA: g_cell TYPE ole2_object.
    DATA: g_cell1 TYPE ole2_object.
    DATA: g_cell2 TYPE ole2_object.
    DATA: g_cellrange TYPE ole2_object.
    DATA: g_font TYPE ole2_object.
    DATA: g_interior TYPE ole2_object.
    DATA: g_borders TYPE ole2_object.
    DATA: g_first_ws VALUE 'Y'.
    DATA: g_row TYPE i.
    DATA: g_col TYPE i.
    definition of loop counter
    DATA: i TYPE i VALUE '5'.
    DATA: BEGIN OF t_sheet1 OCCURS 1,
    col1(10),
    col2(20),
    END OF t_sheet1.
    DATA: BEGIN OF t_sheet2 OCCURS 1,
    col1(10),
    col2(20),
    END OF t_sheet2.
    START-OF-SELECTION.
      PERFORM prepare_data.
      PERFORM download_to_excel.
    END-OF-SELECTION.
    call method of excel 'QUIT'.
    it is now possible to leave the EXCEL application
    remark: you have to go to the EXCEL application and answer the
    popup dialog screen
    *& Form PREPARE_DATA
    FORM prepare_data.
      t_sheet1-col1 = 'A1'.
      t_sheet1-col2 = 'A2'.
      APPEND t_sheet1.
      t_sheet1-col1 = 'B1'.
      t_sheet1-col2 = 'B2'.
      APPEND t_sheet1.
      t_sheet2-col1 = 'Y1'.
      t_sheet2-col2 = 'Y2'.
      APPEND t_sheet2.
      t_sheet2-col1 = 'Z1'.
      t_sheet2-col2 = 'Z2'.
      APPEND t_sheet2.
    ENDFORM. " PREPARE_DATA
    *& Form DOWNLOAD_TO_EXCEL
    FORM download_to_excel.
      PERFORM open_excel.
      PERFORM add_worksheet1.
      PERFORM add_worksheet2.
      PERFORM open_template_file.
      PERFORM close_excel.
      WRITE: / 'End of program'.
    ENDFORM. " DOWNLOAD_TO_EXCEL
    *& Form FILL_CELL
    *& FORM routine, which fills the specified cell in the EXCEL sheet
    *& with the given value
    FORM fill_cell USING i_row TYPE i
    i_col TYPE i
    i_value
    i_fontbold
    i_digit
    i_wraptext
    i_horizon_align
    i_vertical_align.
      DATA: l_str TYPE string.
      CALL METHOD OF g_excel 'CELLS' = g_cell
        EXPORTING #1 = i_row
        #2 = i_col.
      SET PROPERTY OF g_cell 'VALUE' = i_value.
      IF i_fontbold = 'X'.
        GET PROPERTY OF g_cell 'Font' = g_font.
        SET PROPERTY OF g_font 'Bold' = 1.
      ENDIF.
      IF NOT i_wraptext IS INITIAL.
        SET PROPERTY OF g_cell 'WrapText' = 1.
      ENDIF.
      IF NOT i_horizon_align IS INITIAL.
        IF i_horizon_align = 'L'.
          SET PROPERTY OF g_cell 'HorizontalAlignment' = xlleft.
        ELSEIF i_horizon_align = 'R'.
          SET PROPERTY OF g_cell 'HorizontalAlignment' = xlright.
        ELSEIF i_horizon_align = 'C'.
          SET PROPERTY OF g_cell 'HorizontalAlignment' = xlcenter.
        ENDIF.
      ENDIF.
      IF NOT i_vertical_align IS INITIAL.
        IF i_vertical_align = 'T'.
          SET PROPERTY OF g_cell 'VerticalAlignment' = xltop.
        ELSEIF i_vertical_align = 'B'.
          SET PROPERTY OF g_cell 'VerticalAlignment' = xlbottom.
        ELSEIF i_vertical_align = 'C'.
          SET PROPERTY OF g_cell 'VerticalAlignment' = xlcenter.
        ENDIF.
      ENDIF.
    To set number format for cell
      IF i_digit <> ''.
        IF i_value IS INITIAL AND i_digit <> '%'.
          SET PROPERTY OF g_cell 'VALUE' = ''.
        ELSE.
    Set number format for cell with number
          IF i_digit = '1'.
            SET PROPERTY OF g_cell 'NumberFormat' = '#,###.0 '.
          ELSEIF i_digit = '2'.
            SET PROPERTY OF g_cell 'NumberFormat' = '#,##0.00 '.
          ELSEIF i_digit = '%'.
            SET PROPERTY OF g_cell 'NumberFormat' = '#,##0.00% '.
          ELSE.
            SET PROPERTY OF g_cell 'NumberFormat' = '#,### '.
          ENDIF.
        ENDIF.
      ENDIF.
      ADD 1 TO i_col.
    ENDFORM.                    "FILL_CELL
    *& Form OPEN_EXCEL
    FORM open_excel.
      DATA: l_cnt TYPE i.
    create object excel of OLE class 'EXCEL.APPLICATION'
      CREATE OBJECT g_excel 'EXCEL.APPLICATION'.
      CALL METHOD OF g_excel 'WORKBOOKS' = g_workbooks.
      CALL METHOD OF g_workbooks 'ADD' = g_workbook.
      GET PROPERTY OF g_workbook 'Worksheets' = g_worksheets.
      GET PROPERTY OF g_excel 'ACTIVESHEET' = g_worksheet.
      SET PROPERTY OF g_excel 'DISPLAYALERTS' = 0.
      GET PROPERTY OF g_worksheets 'Count' = l_cnt.
      l_cnt = l_cnt - 1.
    Delete unwanted worksheets
      DO l_cnt TIMES.
        GET PROPERTY OF g_excel 'ACTIVESHEET' = g_worksheet.
        CALL METHOD OF g_worksheet 'DELETE'.
      ENDDO.
    ENDFORM. " OPEN_EXCEL
    *& Form CLOSE_EXCEL
    FORM close_excel.
      SET PROPERTY OF g_excel 'VISIBLE' = 1.
      CALL METHOD OF g_workbook 'SAVEAS'
        EXPORTING #1 = p_filenm.
    quit Excel and free all OLE objects
    call method of g_excel 'QUIT'.
      FREE OBJECT g_interior.
      FREE OBJECT g_borders.
      FREE OBJECT g_font.
      FREE OBJECT g_cell.
      FREE OBJECT g_cell1.
      FREE OBJECT g_cell2.
      FREE OBJECT g_cellrange.
      FREE OBJECT g_excel.
      FREE OBJECT g_workbooks.
      FREE OBJECT g_workbook.
      FREE OBJECT g_worksheets.
      FREE OBJECT g_worksheet.
    ENDFORM. " CLOSE_EXCEL
    *& Form ADD_WORKSHEET
    FORM add_worksheet USING i_name.
    Add new worksheet
      IF g_first_ws <> 'N'.
        g_first_ws = 'N'.
        GET PROPERTY OF g_excel 'ACTIVESHEET' = g_worksheet.
      ELSE.
        CALL METHOD OF g_worksheets 'Add' = g_worksheet.
      ENDIF.
      SET PROPERTY OF g_worksheet 'NAME' = i_name.
      g_row = 1.
      g_col = 1.
    ENDFORM. " ADD_WORKSHEET
    *& Form ADD_WORKSHEET1
    FORM add_worksheet1.
      PERFORM add_worksheet USING 'Test 1'.
    fill line in EXCEL sheet with headerlines of table columns
      g_col = 1.
      PERFORM fill_cell USING g_row g_col 'My First Worksheet' 'X' ''
      PERFORM merge_cell USING g_row 1 g_row 4.
      PERFORM set_border USING g_row 1 g_row 4 4 ''.
      ADD 1 TO g_row.
      g_col = 1.
      PERFORM fill_cell USING g_row g_col 'ID'(001) 'X' '' '' '' ''.
      PERFORM fill_cell USING g_row g_col 'Name'(002) 'X' '' '' '' ''.
      PERFORM fill_cell USING g_row g_col 'Telephon'(003) 'X' '' '' '' ''.
      PERFORM fill_cell USING g_row g_col 'Rabatt'(004) 'X' '' '' '' ''.
    loop at customr table and print values into EXCEL sheet
      ADD 1 TO g_row.
      LOOP AT t_sheet1.
        g_col = 1.
        PERFORM fill_cell USING g_row g_col t_sheet1-col1 '' '' '' '' ''.
        PERFORM fill_cell USING g_row g_col t_sheet1-col2 '' '' '' '' ''.
        ADD 1 TO g_row.
      ENDLOOP.
      g_col = 4.
      PERFORM set_border USING 1 1 g_row g_col '' 4.
    ENDFORM. " ADD_WORKSHEET1
    *& Form ADD_WORKSHEET2
    FORM add_worksheet2.
      PERFORM add_worksheet USING 'Test 2'.
    fill line in EXCEL sheet with headerlines of table columns
      g_col = 1.
      PERFORM fill_cell USING g_row g_col 'My Second Worksheet' 'X' ''
      PERFORM merge_cell USING g_row 1 g_row 4.
      PERFORM set_border USING g_row 1 g_row 4 1 'X'.
      PERFORM set_color USING g_row 1 g_row 4 'LT'.
      ADD 1 TO g_row.
      g_col = 1.
      PERFORM fill_cell USING g_row g_col 'ID'(001) 'X' '' '' '' ''.
      PERFORM fill_cell USING g_row g_col 'Name'(002) 'X' '' '' '' ''.
      PERFORM fill_cell USING g_row g_col 'Telephon'(003) 'X' '' '' '' ''.
      PERFORM fill_cell USING g_row g_col 'Rabatt'(004) 'X' '' '' '' ''.
    loop at customr table and print values into EXCEL sheet
      ADD 1 TO g_row.
      LOOP AT t_sheet2.
        g_col = 1.
        PERFORM fill_cell USING g_row g_col t_sheet2-col1 '' '' '' '' ''.
        PERFORM fill_cell USING g_row g_col t_sheet2-col2 '' '' '' '' ''.
        ADD 1 TO g_row.
      ENDLOOP.
      g_col = 4.
      PERFORM set_border USING 1 1 g_row g_col 2 'X'.
      ADD 4 TO g_row.
      g_col = 1.
      PERFORM fill_cell USING g_row g_col 'This is a wrap text' 'X' ''
      'X' 'C' 'T'.
      PERFORM fill_cell USING g_row g_col 'Vertical - Bottom' 'X' ''
      '' 'L' 'T'.
      ADD 4 TO g_row.
      g_col = 1.
      PERFORM fill_cell USING g_row g_col 'Amount 1' 'X' '' '' '' ''.
      PERFORM fill_cell USING g_row g_col '100.04' '' 'X' '' '' ''.
      ADD 1 TO g_row.
      g_col = 1.
      PERFORM fill_cell USING g_row g_col 'Amount 2' 'X' '' '' '' ''.
      PERFORM fill_cell USING g_row g_col '200.01' '' 'X' '' '' ''.
      ADD 1 TO g_row.
      g_col = 1.
      PERFORM fill_cell USING g_row g_col 'Total' 'X' '' '' '' ''.
      PERFORM fill_cell USING g_row g_col '=SUM(B13:B14)' 'X' 'X' '' '' ''.
      PERFORM fill_cell USING g_row g_col '0.00' 'X' 'X' '' '' ''.
      PERFORM copy_cell USING g_row 2 17 5 25 8.
    ENDFORm. " ADD_WORKSHEET2
    *& Form MERGE_CELL
    FORM merge_cell USING i_row1 i_col1
    i_row2 i_col2.
      CALL METHOD OF g_excel 'Cells' = g_cell1
        EXPORTING #1 = i_row1
        #2 = i_col1.
      CALL METHOD OF g_excel 'Cells' = g_cell2
        EXPORTING #1 = i_row2
        #2 = i_col2.
      CALL METHOD OF g_excel 'Range' = g_cellrange
        EXPORTING #1 = g_cell1
        #2 = g_cell2.
      CALL METHOD OF g_cellrange 'Merge'.
    ENDFORM. " MERGE_CELL
    *& Form SET_BORDER
    FORM set_border USING i_row1 i_col1
    i_row2 i_col2
    i_thickness
    i_allborders.
      CALL METHOD OF g_excel 'Cells' = g_cell1
        EXPORTING #1 = i_row1
        #2 = i_col1.
      CALL METHOD OF g_excel 'Cells' = g_cell2
        EXPORTING #1 = i_row2
        #2 = i_col2.
      CALL METHOD OF g_excel 'Range' = g_cellrange
        EXPORTING #1 = g_cell1
        #2 = g_cell2.
      IF i_allborders IS INITIAL.
        CALL METHOD OF g_cellrange 'BorderAround'
        EXPORTING #1 = 1 "Continuous line
        #2 = i_thickness. "Thickness: 1 - Normal, 4 - Thick
      ELSE.
        GET PROPERTY OF g_cellrange 'Borders' = g_borders.
        SET PROPERTY OF g_borders 'LineStyle' = '1'.
        SET PROPERTY OF g_borders 'Weight' = i_thickness.
      ENDIF.
    ENDFORM. " SET_BORDER
    *& Form SET_COLOR
    FORM set_color USING i_row1 i_col1
    i_row2 i_col2
    i_color.
      DATA: l_colorindex TYPE i.
      CASE i_color.
        WHEN 'BK'.
          l_colorindex = 1. "Black
        WHEN 'BR'.
          l_colorindex = 53. "Brown
        WHEN 'OG'.
          l_colorindex = 52. "Olive Green
        WHEN 'DG'.
          l_colorindex = 51. "Dark Green
        WHEN 'DT'.
          l_colorindex = 49. "Dark Teal
        WHEN 'DB'.
          l_colorindex = 11. "Dark Blue
        WHEN 'ID'.
          l_colorindex = 55. "Indigo
        WHEN 'G4'.
          l_colorindex = 56.                                    "Gray 80%
        WHEN 'DR'.
          l_colorindex = 9. "Dark Red
        WHEN 'OR'.
          l_colorindex = 46. "Orange
        WHEN 'DY'.
          l_colorindex = 12. "Dark Yellow
        WHEN 'GR'.
          l_colorindex = 10. "Green
        WHEN 'TL'.
          l_colorindex = 14. "Teal
        WHEN 'BL'.
          l_colorindex = 5. "Blue
        WHEN 'BY'.
          l_colorindex = 47. "Blue Gray
        WHEN 'G3'.
          l_colorindex = 16.                                    "Gray 50%
        WHEN 'RD'.
          l_colorindex = 3. "Red
        WHEN 'LO'.
          l_colorindex = 45. "Light Orange
        WHEN 'LI'.
          l_colorindex = 43. "Lime
        WHEN 'SG'.
          l_colorindex = 50. "Sea Green
        WHEN 'AQ'.
          l_colorindex = 42. "Aqua
        WHEN 'LB'.
          l_colorindex = 41. "Light Blue
        WHEN 'VL'.
          l_colorindex = 13. "Violet
        WHEN 'G2'.
          l_colorindex = 48.                                    "Gray 40%
        WHEN 'PK'.
          l_colorindex = 7. "Pink
        WHEN 'GD'.
          l_colorindex = 44. "Gold
        WHEN 'YL'.
          l_colorindex = 6. "Yellow
        WHEN 'BG'.
          l_colorindex = 4. "Bright Green
        WHEN 'TQ'.
          l_colorindex = 8. "Turquoise
        WHEN 'SB'.
          l_colorindex = 33. "Sky Blue
        WHEN 'PL'.
          l_colorindex = 54. "Plum
        WHEN 'G1'.
          l_colorindex = 15.                                    "Gray 25%
        WHEN 'RS'.
          l_colorindex = 38. "Rose
        WHEN 'TN'.
          l_colorindex = 40. "Tan
        WHEN 'LY'.
          l_colorindex = 36. "Light Yellow
        WHEN 'LG'.
          l_colorindex = 35. "Light Green
        WHEN 'LT'.
          l_colorindex = 34. "Light Turquoise
        WHEN 'PB'.
          l_colorindex = 37. "Pale Blue
        WHEN 'LV'.
          l_colorindex = 39. "Lavender
        WHEN 'WH'.
          l_colorindex = 2. "White
        WHEN OTHERS.
          l_colorindex = 2. "White
      ENDCASE.
      CALL METHOD OF g_excel 'Cells' = g_cell1
        EXPORTING #1 = i_row1
        #2 = i_col1.
      CALL METHOD OF g_excel 'Cells' = g_cell2
        EXPORTING #1 = i_row2
        #2 = i_col2.
      CALL METHOD OF g_excel 'Range' = g_cellrange
        EXPORTING #1 = g_cell1
        #2 = g_cell2.
      GET PROPERTY OF g_cellrange 'Interior' = g_interior.
      SET PROPERTY OF g_interior 'ColorIndex' = l_colorindex.
    ENDFORM. " SET_COLOR
    *& Form COPY_CELL
    FORM copy_cell USING i_crow i_ccol
    i_prow1 i_pcol1
    i_prow2 i_pcol2.
      CALL METHOD OF g_excel 'Cells' = g_cell
        EXPORTING #1 = i_crow
        #2 = i_ccol.
      CALL METHOD OF g_cell 'Copy'.
      CALL METHOD OF g_excel 'Cells' = g_cell1
        EXPORTING #1 = i_prow1
        #2 = i_pcol1.
      CALL METHOD OF g_excel 'Cells' = g_cell2
        EXPORTING #1 = i_prow2
        #2 = i_pcol2.
      CALL METHOD OF g_excel 'Range' = g_cellrange
        EXPORTING #1 = g_cell1
        #2 = g_cell2.
      CALL METHOD OF g_worksheet 'Paste'
        EXPORTING #1 = g_cellrange.
    ENDFORM. " COPY_CELL
    *& Form OPEN_TEMPLATE_FILE
    FORM open_template_file.
      CALL METHOD OF g_workbooks 'Open' = g_tmp_workbook
        EXPORTING #1 = g_pc_template
        #2 = 2
        #3 = 0
        #4 = 1
        #5 = 0
        #6 = 0
        #7 = 1.
      CALL FUNCTION 'FLUSH'
        EXCEPTIONS
          OTHERS = 0.
      GET PROPERTY OF g_tmp_workbook 'Worksheets' = g_tmp_worksheets.
      GET PROPERTY OF g_tmp_worksheets 'Item' = g_tmp_worksheet1
      exporting #1 = 1.
      GET PROPERTY OF g_tmp_worksheets 'Item' = g_tmp_worksheet2
      exporting #1 = 2.
      CALL METHOD OF g_tmp_worksheet1 'Copy'
        EXPORTING #1 = g_worksheet.
      CALL METHOD OF g_tmp_worksheet2 'Copy'
        EXPORTING #1 = g_worksheet.
    call method of g_tmp_workbook 'Close'.
      CALL FUNCTION 'FLUSH'
        EXCEPTIONS
          OTHERS = 0.
    ENDFORM. " OPEN_TEMPLATE_FILE

  • Function Module for calculating hours between dates and their times.

    Hi all,
    Is there any standard function module for calculating the time difference in hours between two dates with start and end times.
    Regards,
    Sudipto.

    Sudipto,
    How're you ????????????????????
    Check out the following Function Module:
    SD_DATETIME_DIFFERENCE (Give the difference in Days and Time for 2 dates)
    Regards,
    Abir
    Don't forget to award Points *

  • Function Module for PM Order Change?

    Hello Everyone,
    I want to change a plant maintenance Order's Header Data, operations list  and object list.
    Is there any existing function module for this.
    R/3 version which I am using is 4.6c.
    I have found a function module 'ALM_ME_ORDER_CHANGE' but unable to change any of the order's data using this.
    Thanks & Regards,
    Swati

    Hi,
    Here is  the Function Module  :  BAPI_ALM_ORDER_MAINTAIN
    Reward  Points if it is usefull..
    Girish

  • Is their any function module for deleting condition record i am trying

    Hi Experts,
    Is their any function module for deleting condition record i am trying  this way.......
    DATA: TABLE (4) TYPE C.
    DATA: KNUM LIKE KONH-KNUMH
    DATA: K_VEWE LIKE T681-KVEWE VALUE 'A'.
    DATA: T681_STR LIKE T681.
    DATA: LV_NUM TYPE I.
    GET PARAMETERS
    PARAMETERS: TABNO LIKE T681-KOTABNR.
    PARAMETERS: TESTMODE DEFAULT 'X' AS CHECKBOX.
    REFRESH INT_KNUMH.
    Select single * from T681 into T681_STR
    where kvewe = K_VEWE AND
    KOTABNR = TABNO.
    IF SY-SUBRC NE 0.
    WRITE: / 'No entry in T681 for number ', TABNO.
    WRITE: / 'Check whether corresponding condition table exists.'.
    EXIT.
    ENDIF.
    TABLE = T681_STR-KOTAB.
    SELECT KNUMH FROM (TABLE) INTO KNUM.
    SELECT SINGLE * FROM KONH WHERE KNUMH = KNUM.
    IF SY-SUBRC NE 0.
    INT_KNUMH-KNUMH = KNUM.
    COLLECT INT_KNUMH.
    ENDIF.
    ENDSELECT.
    DESCRIBE TABLE INT_KNUMH LINES LV_NUM.
    IF LV_NUM EQ 0.
    WRITE: / 'No inconsistent entries found.'.
    WRITE: / 'Each record in the condition table has a corresponding.'.
    WRITE: / 'entry in the KONH table.'.
    EXIT.
    ENDIF.
    LOOP AT INT_KNUMH.
    IF TESTMODE IS INITIAL.
    DELETE FROM (TABLE) WHERE
    KNUMH = INT_KNUMH-KNUMH.
    IF SY-SUBRC = 0.
    WRITE: / 'KNUMH =', INT_KNUMH-KNUMH(10), ' deleted from table ' ,TABLE.
    ELSE.
    WRITE: / 'DELETE: SY-SUBRC is', SY-SUBRC , ' FOR KNUMH = ' .
    WRITE: INT_KNUMH-KNUMH(10).
    ENDIF.
    ELSE.
    WRITE: / 'TESTRUN: KNUMH =', INT_KNUMH-KNUMH(10).
    ENDIF.
    ENDLOOP.
    is their any Standerd Function module  for comparing  tables if the condition record not exist in it has to exit if it is their then compare  those two tables if not exist in one table also that has  to be delete  the condition record
    Please let me know .....

    Hi,
       You can use Function module PRICING_CHECK to check condition record. Do a where-used list on it to see how to call it.
    Regards
    Kiran Sure

  • Function module for Open Sales Orders.

    Can u any one tell me is there any standard function module to
    retrieve OPEN-SALES orders. I tried to debug VA05 but not of use...
    Thanks in advance,
    Sanjay.

    hi
      you can get open sales orders from vbuk and vbup
        SELECT
             A~VBELN
             A~GBSTK
             B~GBSTA FROM VBUK AS A
             INNER JOIN VBUP AS B
             ON AVBELN = BVBELN  INTO TABLE T_OPENS
             FOR ALL ENTRIES IN T_VBELN WHERE A~VBELN = T_VBELN-VBELN
            AND  A~GBSTK IN ('A','B')
             AND B~GBSTA IN ('A','B').
    in t_vebeln table is haveing sales orders by user selection you can get it like this
    regards,
    varma

Maybe you are looking for

  • Fake Adobe 24/7 help tech's

    Hi:    This is a warning. I posted an issue here on Friday and was contacted on Saturday via e:mail. The claimed to be with Adobe24/7 help requested to connect on Skype messaging. The icon on the  Skype was Adobe helps.     This tech and one that pho

  • Reset Portal password

    Hi All, I want to reset the passowrd of portal of some users. when i go to user admin --->search and then click on modify , Iam unable to see the field such as automatic passowrd generation , Password and confirm password field for some of the users.

  • Volume levels when burning finished product

    I just burned a project from imovie 11 onto a dvd using idvd. The volume came out much lower on the burned dvd than it was in imovie. Is this common? If I finalize and/or do expert settings and then burn the project, will that help? Or do I need to b

  • Online Availability of Sun ONE Application Server User Groups

    The Sun ONE Application Server User Group community is now available online at http://developer.iplanet.com/usergroups/appserverhome.jsp Sanjay

  • Freigestellte Bilder von PS in PM

    Eigentlich möchte ich etwas ganz einfaches erledigen. Man nehme ein Bild mit 4 Ecken und zeichne eine z.b. Elipse darum, danach Auswahl umkehren und dann Delete. Somit sollten ja die Ecken gelöscht sein. Wie bringe ich nun dieses Bild in den Pagemake