Credit Memo Request - Warning Message

Hi,
We need to have Warning message to be displayed when we have the credit value exceeds the invoice value during the Credit Memo request creation with reference to the invoice.
Currently, as per SAP Standard the system is throwing an information message when the credit value exceeds the invoice value.
In the same requirement, we need to have a report for which we have the credit value exceeds the invoice value.
Please help !
Regards

Hi,
You can control the quantity to be copied into Credit memo request through Copy Controls Quantity Update.
The the same quantity will be copied from the reference document into target document.
You are getting error as Credit Memo Request exists , because you have created the Credit Memo request for full Sales Order Qunatity.
Regards
Krishna

Similar Messages

  • Message V1478 - Credit memo request with reference to an invoice

    Dear all,
    Creating a credit memo request with reference to an invoice, I get the following message "Material in item 000060 does not exist in plant/storage location".
    Of course, this material exists in the plant and the storage location, as we could create the invoice without any problem.
    Any idea?
    Best regards,
    Iné

    Hello
    Generally, these errors may appear due to:
    - The plant is marked for deletion.
    - The plant should be copied from the referenced item.
    So, I would suggest you to
    - Check copying control for Invoice to Credit memo request, particularly, item.
    - Try and create Credit Memo Request with reference to sales order.
    - Or if you want rectify a invoice, then use invoice coreection request.
    Thanks & Regards
    JP

  • Credit memo request with zero net value

    Hello all,
    when we create a credit memo request (VA01, doc type CR) and put a material quantity into the credit memo request that falls below the scale in VK13, the net value for the material will be zero.
    We do not want to allow to save the credit memo request with a zero net value, but SAP will just allow us do that.
    I was wondering if there is a way to pop up a warning or even an error message that avoids saving the document in case of a zero net value?
    Thanks
    Anne

    Hi,
    You can make the condition type (for which $0.00 is not allowed) as mandatory condition type in the pricing procedure. By this way the system will give error and wont allow to proceed any further unless the data is complete. (make sure this is not affecting your regular sales order cycle).
    Or if you just want to give a pop-up message then you can use user exit USEREXIT_SAVE_DOCUMENT_PREPARE in include MV45AFZZ
    Regards,

  • Credit Memo Request already exists for item & 1 , & 2, etc

    Hi SD guru's,
    I am trying to create a credit memo request in reference to my sales order invoice and i am getiing this warning message "Credit Memo Request already exists for item ".
    How is this possible,when i am creating the credit memo request only for the 1st time. Message number displayed is V1498, can you please help me solve this issue.
    Also when i manage to enter into the credit memo request document by pressing enter to all those warning's, i am asked to enter the target quantity. How do i handle this? since i have maintained order quantity in my sales order and my sales invoice.
    Message number displayed is V1498, can you please help me solve this issue.
    Waiting for your kind help.
    Regards
    Ravi.D.Mansharamani

    Hi,
    You can control the quantity to be copied into Credit memo request through Copy Controls Quantity Update.
    The the same quantity will be copied from the reference document into target document.
    You are getting error as Credit Memo Request exists , because you have created the Credit Memo request for full Sales Order Qunatity.
    Regards
    Krishna

  • Credit Memo Request in VA01

    Dear,
    Process : Actually , I am going to create CR memo request in VA01 without reference of Invoice . So ,in this case ,I have got one Issue as Z error .Please help me in this issue ,how to solve step be step .
    Note : 1. Actually , I am SD,MM and PS Consultant not ABAP consultant .I got this issue yesterday but still fight with system with debugging level .
    2. ABAP Consultant not available thats why taking charges to solve this issue .
    Advance Thanks ,
    Naren

    First of all thanks for both ,
    Coming to the point ,I went to SE91 and gave the Message Class as ZVIV and clicked on execute .there I have seen 182 Message and I unticked  the Self Explanatory and saved . Now again ,I raised new Credit Memo Request in VA01 and I didnt get before error but I got another erro as " Red round  Mark" with Save  (Control + Save ) .
    The Red Round Mark doesn't stand on screen to capture or else to see the Problem .That is coming and going immediately .
    Note : Please help one this Issue .
    Thanks,
    Naren

  • Creating credit memo request - V1 498 / missing order quantity

    Hi Experts,
    could any of You pls help me with a credit memo creation issue?
    I credit memo needed to be created based on invoice, so configuration  and copy control is done as usual, but I have a failure during CR order creation referring to an invoice F2.
    I got an error message: V1 498 - Credit  already exist for item... - and no qty is transferred to new document
    I have gone thought the threads on Forum, but none of the suggested solution was appropriate to solve the issue:
    - the document flow is updated in copy control ,
    - I can no remove the schedule line flag at VOV7 - the order qty will be missed but target qty is used, and end up incompletition (VU 019 error messge), so billing is faile
    - completition control set as B at VOV7,
    Still have the problem
    Could any of You pls help me - answers will be appreciated.

    V1 498 - Credit already exist for item...
    What the above message means is that lines items have already been used as reference for the creation of credit memo request(s).
    Create a new sales order, delivery and billing document. Then create credit memo request with reference to this new billing document and test.
    In VTAF copy control, at item level, field "Pos./neg. quantity" dictates how the quantity in the source document is affected by copy control.
    PS - I tried to create credit memo with reference to billing document (F2), there were no issues there. Therefore I am taking that the issue is with credit memo request (copied with ref to billing document F2)

  • Problem while doing invoice for Credit memo request

    Hi all
    I very well known that Out boud Delivery is not needed for Credit memo request but after saving the CMR and when i raise the Credit Memo (VF01) system is showing a error message saying "PGI not done for Outbound Delivery 30047402"
    In CMR document type i have set the order related billing and i have removed the billing block also
    I have raised the CMR based on Invoice
    Kindly help me in this regard
    Regards
    BMS

    Hi Raj Aryan Malhotra, Thanks for ur reply
    The setting which u said are already there
    The second one that is, change the copying requirement of header to 11. i did this but this time the message was different "The document is not relevant for billing" . After checking the log i could the follwoing info
    Client                                                   240
    Group Number
    Sales Document Number
    Item Number of the SD Document         000000
    Schedule Line Number                         0016
    Counter in Control Tables                     00
    Message Identification                         VF
    System Message Number                    016
    Output Type                                        I
    Message Variable 01
    Message Variable 02
    Message Variable 03
    Message Variable 04
    Group Type                                         F
    Kindly help me to resolve this also
    Regards
    BMS

  • GL account missing in credit memo request

    Hello every one,
    I am trying to creat credit memo request with ref to credit contract invoice but receiving a Document Incomplete message(GL account missing). Iu2019ve clicked on the Edit button and gone back and reviewed everything but I still canu2019t complete the process as I still keep getting the Document Incomplete message.  Can you please advise me.
    Thanks
    Dev

    Dear Sachindev,
    In general, Problem: G/L missing, is assosiated with Settings, maintained in T. Code: VKOA.
    Just Check
    Best Regards,
    Amit
    Dear Sachindev,
    In general, Problem: G/L missing, is assosiated with Settings, maintained in T. Code: VKOA.
    Just Check
    Best Regards,
    Amit
    Note: In T. Code: VA02, key-in your Sales Doc (in your case, Credit Memo Request) and go in to Sales Doc.
    From Menu-bar, Click:
    Edit --> Incompletion Log.
    This will lead to eror page, listing Error: G/L missing.
    Select line and click Tab: Complete Data
    This will lead you to another Screen: Analysis Account Determination
    Now, at left-side of the screen, you can see Columns: Procedure and Description.
    There, you will find
    KOFI --> PR00 (open drop-down option for PR00) --> 10 (KOFI) Cust.Grp/Material Grp/Acct.Key
    Double Click on it.
    IMP1: Instead of KOFI, it could be KOFK also; and instead of "Cust.Grp/Material Grp/Acct.Key", it could be "Cust.Grp/Account Key" or "Material Grp/Acct Key". Just note-down the entries, it will help you to assign G/L in T. Code: VKOA
    Now, at right-hand side of the Screen (i.e. Overview), You will find Access details 10 (KOFI)
    Now, there are two options:
    1. either System will determine the G/L, or
    2. still, G/L a/c missing
    In second case, down there on the same screen, notice the following:
    Field in condition table--Field in document---Value in doc.
    IMP2: Note-down the entries, under Column: Value in doc. as this will help you to maintain settings in T. Code: VKOA
    Now, go to - T. Code: VKOA
    Click on Table: 1 - Cust.Grp/Material Grp/Acct.Key (or as found in step IMP1)
    On to next screen, click Tab: New Entries
    now, maintain entries in to Fields:
    App: V
    CndTy.: KOFI (or as found in step IMP2)
    ChAc: INT (or as found in step IMP2)
    SOrg: 1234 (or as found in step IMP2)
    AAG: 01 (or as found in step IMP2)
    AAG: 05 (or as found in step IMP2)
    ActKy: ERL (or as found in step IMP2)
    G/L Account: You will get it from Accounts dept.
    Provision acc.: I don't think its reqd. as its being used for, say Rev. recog.
    Save the entry. Now, check the Sales Doc. in VA02 (as explained in the statring of Note).

  • Problem while creating credit memo request using BAPI

    HI,
    I am trying to create credit memo request using the BAPI_SALESDOCU_CREATEFROMDATA1..
    I am getting the error as " No customer master data is available for the customer". But the customer exists in the KNA1 table. What is the mistake i hv done.. this s my code..
    REPORT  ZSV_CREDITMEMO_TEST1.
    Data declarations.
    DATA: v_vbeln            LIKE vbak-vbeln.
    DATA: header             LIKE bapisdhead1.
    DATA: headerx            LIKE bapisdhead1x.
    DATA: item               LIKE bapisditem  OCCURS 0 WITH HEADER LINE.
    DATA: itemx              LIKE bapisditemx OCCURS 0 WITH HEADER LINE.
    DATA: partner            LIKE bapipartnr  OCCURS 0 WITH HEADER LINE.
    DATA: return             LIKE bapiret2    OCCURS 0 WITH HEADER LINE.
    DATA: lt_schedules_inx   TYPE STANDARD TABLE OF bapischdlx
                             WITH HEADER LINE.
    DATA: lt_schedules_in    TYPE STANDARD TABLE OF bapischdl
                             WITH HEADER LINE.
    DATA: lt_schedules_ink    TYPE STANDARD TABLE OF bapisdhead1
                             WITH HEADER LINE.
    START-OF-SELECTION.
    Header data
    Sales document type
      header-doc_type = 'G2'. 
      headerx-doc_type = 'X'.
    Sales organization
      header-sales_org = '0001'.
      headerx-sales_org = 'X'.
    Distribution channel
      header-distr_chan  = ''.
      headerx-distr_chan = 'X'.
    Division
      header-division = ''.
      headerx-division = 'X'.
      headerx-updateflag = 'I'.
    *Complete delivery
        header-COMPL_DLV = ''.
        header-COMPL_DLV = 'X'.
    Partner data
    Sold to
      partner-partn_role = 'AG'.
      partner-partn_numb = '0000C10130'.
      APPEND partner.
    Ship to
      partner-partn_role = 'WE'.
      partner-partn_numb = ''.
      APPEND partner.
    ITEM DATA
      itemx-updateflag = 'I'.
    Line item number.
      item-itm_number = '000010'.
      itemx-itm_number = 'X'.
    Material
      item-material = 'C20011'.
      itemx-material = 'X'.
    Plant
      item-plant    = ''.
      itemx-plant   = 'X'.
    Quantity
      item-target_qty = '10000'. 
      itemx-target_qty = 'X'.
    item category
      itemx-ITEM_CATEG = 'X'.
      APPEND item.
      APPEND itemx.
      Fill schedule lines
      lt_schedules_in-itm_number = '000010'.
      lt_schedules_in-sched_line = '0001'.
      lt_schedules_in-req_qty    = '10000'.
      APPEND lt_schedules_in.
      Fill schedule line flags
      lt_schedules_inx-itm_number  = '000010'.
      lt_schedules_inx-sched_line  = '0001'.
      lt_schedules_inx-updateflag  = 'X'.
      lt_schedules_inx-req_qty     = 'X'.
      APPEND lt_schedules_inx.
    Call the BAPI to create the sales order.
      CALL FUNCTION 'BAPI_SALESDOCU_CREATEFROMDATA1'
           EXPORTING
                sales_header_in     = header
                sales_header_inx    = headerx
           IMPORTING
                salesdocument_ex    = v_vbeln
           TABLES
                return              = return
                sales_items_in      = item
                sales_items_inx     = itemx
                sales_schedules_in  = lt_schedules_in
                sales_schedules_inx = lt_schedules_inx
                sales_partners      = partner.
    Check the return table.
      LOOP AT return WHERE type = 'E' OR type = 'A'.
        EXIT.
      ENDLOOP.
      IF sy-subrc = 0.
        WRITE: / 'Error in creating document'.
      ELSE.
    Commit the work.
        COMMIT WORK AND WAIT.
        WRITE: / 'Document ', v_vbeln, ' created'.
      ENDIF.
    can anyone tell what the error is.?

    Hi
    please look at code below code this succefully creating credit memo may some help to you
    header-doc_type = 'ZS4'.
        PERFORM get_plant.
        headerx-doc_type    = 'X'.
        header-sales_org    = wa_temp1-vkorg.
        headerx-sales_org   = 'X'.
        header-purch_no     = wa_temp1-bstnk.
        header-distr_chan   = wa_temp1-vtweg.
        headerx-distr_chan  = 'X'.
        header-division     = wa_temp1-spart.
        header-purch_no_s   = wa_temp1-bstnk.
        headerx-division    = 'X'.
        wa_partner-partn_role = 'AG'.
        wa_partner-partn_numb = wa_temp1-kunnr.
        APPEND wa_partner TO it_partner.
        wa_partner-partn_role = 'WE'.
        wa_partner-partn_numb = wa_temp1-kunnr.
        APPEND wa_partner TO it_partner.
        CLEAR: wa_partner.
        LOOP AT lt_temp2 INTO wa_temp2 WHERE kunnr = wa_temp1-kunnr.
          "AND matnr = wa_temp1-matnr.
    *wa_item-itm_number = wa_temp2-posnr .
          wa_item-material   = wa_temp2-matnr.
          wa_item-plant      = wa_temp2-werks.
          wa_item-req_qty    = wa_temp2-fkimg * 1000.
          wa_item-target_qty = wa_temp2-fkimg * 1000.
          APPEND wa_item TO it_item.
        ENDLOOP.
        CALL FUNCTION 'BAPI_SALESORDER_CREATEFROMDAT1'
          EXPORTING
            order_header_in       = header
    *   WITHOUT_COMMIT            = ' '
    *   CONVERT_PARVW_AUART       = ' '
         IMPORTING
           salesdocument          = v_vbeln
    *   SOLD_TO_PARTY             =
    *   SHIP_TO_PARTY             =
    *   BILLING_PARTY             =
           return                 = return
          TABLES
           order_items_in         = it_item
           order_partners         = it_partner.
        IF v_vbeln <> space.
          wa_vbeln-vbeln = v_vbeln.
          APPEND wa_vbeln TO lt_vbeln.
          CALL FUNCTION 'BAPI_TRANSACTION_COMMIT'
            EXPORTING
              wait = 'X'.
          HIDE wa_vbeln-vbeln.
          CLEAR: wa_partner,header,v_vbeln, wa_temp2.
          REFRESH: it_partner,it_item.
        ELSE.
    *    LOOP AT return .
          it_error-srno = idx.
          it_error-err_msg = return-message.
          APPEND it_error.
    *    ENDLOOP.
        ENDIF.
        idx = idx + 1.
      ENDLOOP.
    Regards

  • Enter sold-to party debit memo request - credit memo request

    Hi Gurus,
    I have a scenario here while creating a Debit memo request.
    1. I create a Debit memo request with sold-to party 1000
    2. I create a Credit memo request with the same sold-to party 1000.
    That will be saved,
    but when you enter VA02 or VA03 for CMR, a message displays "Enter a Sold-to Party".
    So in VA02, I will refill it with Sold-to party 1000, then I can save it.  But when I view it again, I will encounter the same message again.
    However, if I use a different sold-to party 2000, the CMR will be saved normally, and if you view it via VA02, you will see it is correct (you can see sold-to party 2000).
    Why?  Cant I use the same sold-to party for DMR to CMR?
    Please help....
    Ram

    Check whether the partner functions are mantained properly for customer 1000. Go to VD01 and maintain.
    Regards,
    GSL.

  • Credit memo request creation problem

    Hello Guys,
      I try creating credit  memo request passing all related parameters in FM 'SD_SALESDOCUMENT_CREATE'.
    I get the error 'Document 9992222 doesn't have document category  but  '.
    Message is V2 068 .  It  space before and after but.
    I have passed the document category as 'M', in the header data.
    Please reply, if you know the problem or want more details from me.
    Thanks and Best Regards!
    Sandip

    Hi Guys,
    The Ref_doc_cat was not filled correctly in the BAPI. Hence the error.
    Its working now.
    Thanks!
    Sandip

  • Credit Memo Request (Copy Control)

    Hi everyone. Can anyone give me a hand, please?
    I would like to send an error message if a end-user is trying to create a Credit Memo Request (tr:VA01) with reference to a billing document which has been cancelled (tr: VF11) already. Actually the system let me do that, but the client doesn´t want to support it anymore.
    Thanks in advance.

    You can maintain the Same in the Copy Control between Billing Document to Sales Order in a Routine that if VBELN in VBRK - FKSTO is "X" ,do not allow to maintain / Save the Sales Order.
    Best Regards,
    Ankur

  • Mass change of pricing date and billing date in credit memo request

    Hi,
    Can i change the billing date pricing date on credit memo request docs using MASS transaction?
    If i enter the regular sales order number it prompts me to change the value but if i enter the credit memo request doc number,the message "No data meets the selection criteria" is displayed.I also checked with IDES ,message is the same
    Is there any different way to do mass change for credit memo requests or am i missing something here.
    Please Suggest
    Thanks
    Abhilash Nayak

    Hi,
    Go to the transaction code MASS  and enter the OBJECT  TYPE as BUS2032 and enter
    It will lead you to the next screen where you can find the  Table and Field TABS
    Select the  SALES ORDER HEADER DATA  and choose the fields data and choose the fields PRICING DATE and BILLING DATE  and execute
    In the subsequent screen you can see the selection screen where you can enter all the Sales documents for which you want to change
    Key in all the documents and execute
    Now change the date as per your requirement and check the effect
    regards,
    santosh

  • HOW TO ADD A NEW ITEM ON CREDIT MEMO REQUEST DETAILS PAGE?

    Dear friends,
    Please help me to do this by personalization or extension. This is very important for sustaining in my job. Please post your thoughts as soon as possible.
    Thanks so much for your help and support.
    Here is the scenario:
    In credit memo request page, I need to add a new item.
    In the 'About this page', I checked for the view objects CMRequestVO and CMRequestLinesVO but the item is not available in the view objects.
    There is an item called Requestor Comments shown on this page. The item to be added is the Approver Notes. These 2 columns are populated through the workflow.
    How to find about the Requestor Comments item? If we know this then the Approver Notes item can be easily added to this page, I think.
    Also I enabled the FND_PERSONALIZATION_REGION_LINK profile option so that
    I can create a new item using personalization. But I could not see the create item icon in the create item field.
    Can adding the Approver Notes be achieved by personalization?
    EAGERLY WAITING FOR YOUR HELP.
    CK.

    Hi VK,
    You need to look at both VO's and see where to add the credit memo field.
    To extend the VO object...you have to use Jdeveloper.
    Check the below this site for the details steps:
    http://apps2fusion.com/apps/oa-framework/14-fwk/119-oa-framework-faq-extending-view-objects
    After extending the, you need to copy your objects under webserver and the bounce the apache.
    Then you need to do personalization..
    Here are the steps for personalization:
    Click Personalize page and click "Expand All" under Personalization Structure..
    Go to the corresponding Advance Table and Click on Create Item. This will create a Column Field
    1) Enter Unique ID-- ex; CreditMemoEx
    2) Rendered -- True
    3) Click Apply
    In the advance table search the newly created "CreditMemoEx"
    Click on the Create Item field again.
    1) Select Item Style " Message Styled Text"
    2) Data Type -- Varchar2
    3) Enter the Prompt = "Credit Memo"
    4) Scope -- Enter the full path of VO object...ex: /xx.../oracle/apps/...
    5) View Attribute -- Enter Exact name the attribute defined in the VO object.
    6) Enter other attributes required for Business.
    7) When Finished Click Apply.

  • BAPI to create a credit memo request

    Is there a standard BAPI that can create a credit memo request?
    If not, then can we copy a standard BAPI to a Z-version and amend that?
    Sample code appreciated.
    Thanks,
    John

    The suggestion to use SD_SALESDOCUMENT_CREATE proved fruitful.
    For creating with reference to an invoice:
    Setting ref_doc and ref_doc_ca for each line-item in sales_item_in seems necessary for the creation of the document flow.  Maybe it also brought through other data from the invoice?
    Setting ref_doc and refdoc_cat for sales_header_in caused header text (and maybe other stuff?) to be brought through from the invoice.
    It looks like it will do bills of materials - there's hg_lv_item in sales_items_in - but I've yet to try that.
    Here's the code of a demo program for a one-line CMR.
    REPORT  YJNM_CREATE_CMR5                        .
    Uses SD_SALESDOCUMENT_CREATE
    parameters:
      p_vgbel like vbrk-vbeln  default '90175587', "reference invoice
      p_fkdat like vbkd-fkdat  default sy-datum,   "billing date
      p_auart like tvak-auart  default 'Z002',     "sales document type
      p_vkorg like tvko-vkorg  default '3',        "sales org.
      p_vtweg like tvtw-vtweg  default '01',       "distr. chan.
      p_spart like tspa-spart  default '06',       "division
      p_vkbur like tvbur-vkbur default '034',      "sales office
      p_kunnr like kna1-kunnr  default '16797',    "sold-to
      p_bstnk like vbak-bstnk  default 'pono00000017',
                                                   "PO number
      p_bname like vbak-bname  default 'Bartholomew Snodgrass',
                                                   "name of orderer
      p_augru like tvau-augru  default '002'.      "order reason
    selection-screen skip.
    selection-screen begin of block i1 with frame title text-001.
      parameters:
        p_matnr like mara-matnr default '27585',   "material number
        p_zmeng type dzmengc    default '65',      "target quantity
        p_netwr like vbap-netwr default '1.20',    "net amount
        p_arktx like vbap-arktx default 'Afternoon tea',
                                                   "short text
        p_fbuda like vbkd-fbuda default '20060109'."service-rendered date
    selection-screen end of block i1.
    data:
      return              like bapiret2,
      returns             like table of return,
      salesdocument_ex    like bapivbeln-vbeln,
      sales_header_in     like bapisdhd1,
      sales_item_in       like bapisditm,
      sales_items_in      like table of sales_item_in,
      sales_condition_in  like bapicond,
      sales_conditions_in like table of sales_condition_in,
      sales_partner       like bapiparnr,
      sales_partners      like table of sales_partner,
      incomplete_log      like bapiincomp,
      incomplete_logs     like table of incomplete_log.
    perform:
      fill_sales_header_in,
      fill_sales_items_in,
      fill_sales_partners,
      fill_sales_conditions_in,
      call_bapi.
    FORM call_bapi .
    CALL FUNCTION 'SD_SALESDOCUMENT_CREATE'
      EXPORTING
      SALESDOCUMENT                 =
        SALES_HEADER_IN               = sales_header_in
      SALES_HEADER_INX              =
      SENDER                        =
      BINARY_RELATIONSHIPTYPE       = ' '
      INT_NUMBER_ASSIGNMENT         = ' '
      BEHAVE_WHEN_ERROR             = ' '
      LOGIC_SWITCH                  = ' '
        BUSINESS_OBJECT               = 'BUS2094' "cred. mem. req.
      TESTRUN                       =
      CONVERT_PARVW_AUART           = ' '
      STATUS_BUFFER_REFRESH         = 'X'
      IMPORTING
        SALESDOCUMENT_EX              = salesdocument_ex
      SALES_HEADER_OUT              =
      SALES_HEADER_STATUS           =
      TABLES
        RETURN                        = returns
        SALES_ITEMS_IN                = sales_items_in
      SALES_ITEMS_INX               =
        SALES_PARTNERS                = sales_partners
      SALES_SCHEDULES_IN            =
      SALES_SCHEDULES_INX           =
        SALES_CONDITIONS_IN           = sales_conditions_in
      SALES_CONDITIONS_INX          =
      SALES_CFGS_REF                =
      SALES_CFGS_INST               =
      SALES_CFGS_PART_OF            =
      SALES_CFGS_VALUE              =
      SALES_CFGS_BLOB               =
      SALES_CFGS_VK                 =
      SALES_CFGS_REFINST            =
      SALES_CCARD                   =
      SALES_TEXT                    =
      SALES_KEYS                    =
      SALES_CONTRACT_IN             =
      SALES_CONTRACT_INX            =
      EXTENSIONIN                   =
      PARTNERADDRESSES              =
      SALES_SCHED_CONF_IN           =
      ITEMS_EX                      =
      SCHEDULE_EX                   =
      BUSINESS_EX                   =
        INCOMPLETE_LOG                = incomplete_logs
      EXTENSIONEX                   =
      CONDITIONS_EX                 =
      PARTNERS_EX                   =
      TEXTHEADERS_EX                =
      TEXTLINES_EX                  =
      BATCH_CHARC                   =
    perform imcompletion_log.
    loop at returns into return where type ne 'S'.
      message id return-id type 'I' number return-number
        with
          return-message_v1
          return-message_v2
          return-message_v3
          return-message_v4.
      endloop.
    if salesdocument_ex is initial.
      write: / 'Document not created'.
    else.
      commit work.
      write: / 'Sales document number:', salesdocument_ex.
      endif.
    ENDFORM.                    " call_bapi
    FORM fill_sales_header_in .
    clear sales_header_in.
    move:
      p_fkdat to sales_header_in-bill_date,
      p_vgbel to sales_header_in-ref_doc,    "invoice number
      'M'     to sales_header_in-refdoc_cat, "invoice
      p_auart to sales_header_in-doc_type,
      p_vkorg to sales_header_in-sales_org,
      p_vtweg to sales_header_in-distr_chan,
      p_spart to sales_header_in-division,
      p_vkbur to sales_header_in-sales_off,
      p_bstnk to sales_header_in-purch_no_c,
      p_bname to sales_header_in-name,
      p_augru to sales_header_in-ord_reason.
    ENDFORM.                    " fill_sales_header_in
    FORM fill_sales_partners .
    clear sales_partner.
    sales_partner-partn_role = 'AG'.
    sales_partner-partn_numb = p_kunnr.
    append sales_partner to sales_partners.
    ENDFORM.                    " fill_sales_partners
    FORM fill_sales_items_in .
    perform one_item_in using:
      10
      p_matnr
      p_zmeng
      p_netwr
      'GBP'
      p_arktx
      p_fbuda.
    ENDFORM.                    " fill_sales_items_in
    FORM one_item_in  using    value(p_itm_number)
                               value(p_p_matnr)
                               value(p_p_zmeng)
                               value(p_p_netwr)
                               value(p_p_waerk)
                               value(p_p_arktx)
                               value(p_p_fbuda).
    clear sales_item_in.
    move:
      p_itm_number to sales_item_in-itm_number,
      p_fkdat      to sales_item_in-bill_date,
      p_vgbel      to sales_item_in-ref_doc,    "invoice number
      'M'          to sales_item_in-ref_doc_ca, "invoice
      p_p_matnr    to sales_item_in-material,
      p_p_zmeng    to sales_item_in-target_qty,
      p_p_netwr    to sales_item_in-target_val,
      p_p_waerk    to sales_item_in-currency,
      p_p_arktx    to sales_item_in-short_text,
      p_p_fbuda    to sales_item_in-serv_date.
    append sales_item_in to sales_items_in.
    ENDFORM.                    " one_item_in
    FORM fill_sales_conditions_in .
    refresh sales_conditions_in.
    perform one_sales_condition_in using:
      10
      p_netwr
      'GBP'.
    ENDFORM.                    " fill_sales_conditions_in
    FORM one_sales_condition_in  using    value(p_itm_number)
                                          value(p_p_netwr)
                                          value(p_p_waerk).
    clear sales_condition_in.
    move:
      p_itm_number to sales_condition_in-itm_number,
      'PR00'       to sales_condition_in-cond_type,
      p_p_netwr    to sales_condition_in-cond_value,
      p_p_waerk    to sales_condition_in-currency.
    append sales_condition_in to sales_conditions_in.
    ENDFORM.                    " one_sales_condition_in
    FORM imcompletion_log .
    loop at incomplete_logs into incomplete_log.
      write: / incomplete_log-itm_number,
               incomplete_log-field_text,
               incomplete_log-table_name,
               incomplete_log-field_name.
      endloop.
    ENDFORM.                    " imcompletion_log

Maybe you are looking for

  • Can you use the same form for different datasheets?

    Hello! Thanks in advance for your time. To keep this short, I have created a form at my place of work to do a type of process audit. The form has worked extremely well and now other areas of the business would like to use it. For example, let's say I

  • Assignment with file input

    I'm not one to join boards for the purpose of asking a question, but it's here that I'm stumped, and if anyone could help, I'd really appreciate it. Here's the first part of the task: "Task- Imagine that you are an owner of a hardware store and need

  • AMS Amazon Release now available for Sydney Region

    Adobe Media Server availability on Amazon Web Services has been expanded. Amazon Machine image is now also available for Sydney Region AMI ID - ami-90e071aa Instances Supported m1.large, m1.xlarge, m2.xlarge, m2.2xlarge, m2.4xlarge, c1.xlarge FMS 4.5

  • Problem in idoc transportation

    hi all, i tried to create idoc and i have completed my idoc creation process till t-code we20.now when i go to t-code we60 and try to transport it then it is giving me error that ENTRY IN OUTBOUND TABLE NOT FOUND. REGARDS, VANEET THAKUR

  • Select a Row in a table and display the related in formation

    I have a uix page displaying table "room" ,there are several patients in every room .What I want to do is: Using "SingleSelection" to select a room and display some attributes of this room and the related patients in a table with using another page.