Sales Order iDoc from SAP SCM 7.0

Hi Experts
I have two question fro you guys.
1. Can we generate VMI sales order idoc from SAP SCM 7.0? I know is can generate xml message. If we can generate idoc for VMI sales order from SAP SCM , please give me some direction or path to explore.
2. Can I use idoc to to create to VMI sales order in ECC skiping CIF. But the changes in ECC to these order should use the CIF to update the VMI orders in SAP SCM.
Please share your experience on this.

Hi,
Did you set up this scenario? I want something similar, but I want an ERP order to be created. Do you know if that is possible? Do you have som tips?
regards Camilla

Similar Messages

  • Creating inbound Sales Orders IDOC within SAP

    Hi,
    I receive a flat file containing sales order information. I would like to create inbound Sales Order IDOCs from this flat file. I know I can use BAPI_SALESORDER_CREATEFROMDAT2 to create sales orders however I would like to retain the benefits of IDOCs e.g. error retention and re-processing.
    There are a number of functions MASTERIDOC_CREATE* to create various IDOCs but I can't seem to find one for message type ORDERS. I know I can create a 'Z' version but would like to avoid that as much as possible as development budget is tight.
    Any help would be greatly appreciated in the form of reward points.
    Thanks and regards,
    Liam

    Hi,
    Can u tell me the steps to create a sales order using idoc, i've created a bapi but thats a temprory use. I wanted to created a sales order automatically when a purchase order is saved.
    Please let me know if u can help me, i wanted to do it using idoc
    Regards
    Sanju

  • How to transfer sales order idoc from R/3 to CRM

    Hi,
          I want to generate the sales order idoc in R/3 (ORDERS) and replicates to CRM through XIF adapter.
    The sales documents are not realy existing in R/3. We can only get the information from related biling documents and try to gerenate ORDERS idoc.
    The problem is how to map R/3 idoc to CRM idoc(CRMXIF_ORDER_SAVE_M01). The administration console seems can only send the idocs but not receiving them.
    Thanks,
    Ina

    Hello Yina,
    Can you please answer the questions? I am a little bit confused.
    If you don't have the order in R/3, are you not going to create one when creating the ORDERS IDoc? If yes, then this order will go to CRM automatically if you have the middleware set properly.
    If you are NOT creating any order in R/3 during the IDoc step, Why would you want the order in CRM when you don't have it in R/3?
    Are you not going to keep the middleware between R/3 and CRM open? If you keep it open, the order from CRM will crossover to R/3 - in which case you could have created the order in R/3 in the first step itself !!!
    If you are not keeping the middleware open between R/3 and CRM - I don't know why would you want to keep the orders in CRM, but not in R/3. Is it because of lack of good CRM consultants in the project?
    Easwar Ram
    http://www.parxlns.com

  • Posting sales order idoc from VA02

    Hi all
    I need  to permit to user to launch the a confirm message idoc directly the VA02/VA03 using the output like for normal sales order print, but SAP don't show the EDI messages in that functionality. Exist a possibility to permit the launch EDI output messages type by the VA02 without use the WE15?
    thanks
    Davide

    Hi Wolfgang
    Unluckily the message type 6 (EDI) are blocked to appear  in the output manual dynpro (that where the user can make the preview of message).
    I forced that in the standard:
    RV_MESSAGE_DIALOG
        DELETE gt_xnast WHERE nacha NE postversand
                        and   nacha NE telefax
                        and   nacha NE MAIL_EXTERN
    *{   INSERT                                               1
                        and  nacha NE EDI   "per questo messaggio stampo da interfaccia
    *}   INSERT
                        OR    aktiv NE space
                        OR    updat EQ const_d
                        OR    updat EQ const_l.   " explicit deleted by user
    and for block the preview of this mesage type:
    LVMSGI01
    Functioncode for PREVIEW
        WHEN 'VIEW'.
        Check if an entry is marked
          CHECK count <> 0.
    *{   INSERT                                              1
          check nast-nacha <> '6'.   "niente preview per gli edi
    *}   INSERT
    Davide

  • Send IDoc from SAP SCM to XI

    Hi,
         Can somebody give me step by step procedure to send IDoc form SAP SCM to XI. We are not using ICH. IDoc is coming to SCM through EDI. Once it is posted in SCM, we want to send it to XI. We had a option of sending directly to XI through EDI connectivity, but for some reason we want to post it in SCM and then send it to XI.
    Thanks,
    Sanjay

    hi,
    sending IDOCs to XI is always the same
    apart from documents section in the XI FAQ (link below)
    when you can find some IDOC weblogs
    you can also find lots of configuration examples for IDOC-XI scenarios in my book:
    <a href="/people/michal.krawczyk2/blog/2006/10/11/xi-new-book-mastering-idoc-business-scenarios-with-sap-xi"><b>Mastering IDoc Business Scenarios with SAP XI</b></a>
    Regards,
    michal
    <a href="/people/michal.krawczyk2/blog/2005/06/28/xipi-faq-frequently-asked-questions"><b>XI / PI FAQ - Frequently Asked Questions</b></a>

  • Faxing PDF format of Sales orders/PO from SAP

    Hi,
    My requirement is, when any sales order/PO is created, I have to automatically fax/email the output in PDF format.How do I do that?
    (a)Do I have any user exit/Badi for these standard transaction where I convert the spool to PDF format?
    (b)Even then, can I use the standard output determination technique to send the PDF format out as email or Fax?
    Regards,
    Bhaskar.

    hi ,
    check this link..
    create the output type and trigger the mail/fax program
    via output type.
    http://www.sap-img.com/abap/sending-mail-with-attachment-report-in-background.htm
    http://www.sap-img.com/abap/sending-fax-from-abap.htm
    thanks
    vijay
    Message was edited by: Vijay Babu Dudla

  • Dropped sales order report from SAP

    Team,
    There is a specific requirement regarding sales order..to analyze the  dropped /undelivered order for a period.
    Currently we are entering only those sales orders in the system which can be shipped/delivered to customer..all those SOs which can’t be delivered are not entering in system.
    It is  because if we are entering those orders in the stem, MRP will consider those orders for planning.
    Now we need to include all the sales orders in SAP  and  MRP should only consider such orders which can be shipped. Can we do it in the system?
    Thanks for the advise.
    Regards,
      Vijesh

    MRP should only consider such orders which can be shipped. Can we do it in the system?
    At what stage, you will come to know that sale order can be shipped as planned?  Nevertheless, you can either change the MRP Type in material master to ND or change the schedule line category in sale order to CN so that system will not consider such of those materials for MRP.  You have to decide which one is better but I would prefer the second one as changing the master data quite frequently is not recommended.
    G. Lakshmipathi

  • Email Sales order link from SAP Work Place

    Dear SAP Gurus,
    Well guys i have to mail the sales order link through the work place but its not working for the sales order. but its working for delivery order and billing document...so i want to know that why its not working?
    Regards,
    Mohsin

    Dear All,
    Can u please help me on this situation? I will be very thankful to u....
    Regards,
    Mohsin

  • Sales Order uplaod from JAVA to SAP R/3

    Hi all,
    My cousin is working on uploading Sales Order Document
    from java server to R/3.
    for that he is having a code from JCO jar.
    the below is the file from which one can upload his SO details from JAVA to R/3.
    But in this program he is  just able to upload one Item detail for one Sales document.
    but requirement is to upload 'n' item details for one Sales document.
    Here is the Java code.
    @author pega
    TODO To change the template for this generated type comment go to
    Window - Preferences - Java - Code Style - Code Templates
    Created on Jun 24, 2004
    To change the template for this generated file go to
    Window>Preferences>Java>Code Generation>Code and Comments
    package com.sap.satyam.salesorder;
    import java.sql.Timestamp;
    import java.util.Calendar;
    import com.sap.mw.jco.IFunctionTemplate;
    import com.sap.mw.jco.IRepository;
    import com.sap.mw.jco.JCO;
    public class SalesOrder {
         static final String SID = "R3";
         static final String errorID = "E";
         IRepository repository;
         //String orderNumber = orderCreation("M-01","3000","0002",3,"ST");
         int counter;
         public SalesOrder()
                   try {
                        // Add a connection pool to the specified system
                        JCO.addClientPool(SID,            // Alias for this pool
                                             10,            // Max. number of connections
                                             "800",           // SAP client
                                             "develop",  // userid
                                             "bslabap", // password
                                             "EN",         // language
                                             "172.18.33.20",    // host name
                                             "00");
                        // Create a new repository
                        repository = JCO.createRepository("MYRepository", SID);
                   catch (JCO.Exception ex) {
                        System.out.println("Caught an exception: \n" + ex);
         //     Retrieves and sales order Create
         public void createSalesOrder(String PO_NO, String MAT,String RQTY,String CUSTMAT, String SOLD_NAME, String SOLD_STREET,String SOLD_COUNTRY, String SOLD_POST_CODE,String SHIP_NAME, String SHIP_STREET,String SHIP_COUNTRY, String SHIP_POST_CODE)
              try {
                   // Get a function template from the repository
                   IFunctionTemplate ftemplate = repository.getFunctionTemplate("BAPI_SALESORDER_CREATEFROMDAT1");
                   JCO.MetaData so_metadata = new JCO.MetaData("BAPI_SALESORDER_CREATEFROMDAT1");
                   // Create a function from the template
                   JCO.Function function = new JCO.Function(ftemplate);
                   // Get a client from the pool
                   JCO.Client client = JCO.getClient(SID);
                   // Fill in input parameters
                   // Header
                   JCO.ParameterList input = function.getImportParameterList();
                   JCO.ParameterList tables = function.getTableParameterList();
                   JCO.Structure input_header = input.getStructure("ORDER_HEADER_IN");
                   // Item details
                   JCO.Table table_item = tables.getTable("ORDER_ITEMS_IN");
                   //JCO.Structure input_item = table_item.getStructure("ORDER_ITEMS_IN");
                   // Partner details
                   JCO.Table table_partner = tables.getTable("ORDER_PARTNERS");
                   // Populate the header details
                   input_header.setValue("ZAD5","DOC_TYPE"); // Document Type
                   input_header.setValue("3000","SALES_ORG"); // Sales Organization
                   input_header.setValue("10","DISTR_CHAN");  // Distribution Channel
                   input_header.setValue("00","DIVISION");  // Distribution Channel
                   input_header.setValue("20041212","REQ_DATE_H");// can be changed in yyyymmdd (Requested date)
                   input_header.setValue(PO_NO,"PURCH_NO_C");// can be changed ( Customer PO Number )
                   //Populate the item detalis
                   table_item.appendRow();
                   table_item.setRow(1);
                   table_item.setValue("000010","ITM_NUMBER");
                   table_item.setValue("AA01","PO_ITM_NO");// can be changed
                   table_item.setValue("IAD-SC3000","MATERIAL");
                   table_item.setValue(CUSTMAT,"CUST_MAT");// can be changed
                   table_item.setValue("20041212","REQ_DATE");// can be changed in yyyymmdd
                   table_item.setValue(RQTY,"REQ_QTY");// can be changed Qty * 1000
                   table_item.appendRow();
                   table_item.setRow(2);
                   table_item.setValue("000020","ITM_NUMBER");
                   table_item.setValue("AA01","PO_ITM_NO");// can be changed
                   table_item.setValue("IAD-SC3000","MATERIAL");
                   table_item.setValue(CUSTMAT,"CUST_MAT");// can be changed
                  table_item.setValue("20041212","REQ_DATE");// can be changed in yyyymmdd
                   table_item.setValue(RQTY,"REQ_QTY");// can be changed Qty * 1000
                   //Populate the Partner details
                   // Sold to Party
                   table_partner.appendRow();
                   table_partner.setRow(1);
                   table_partner.setValue("AG","PARTN_ROLE");
                   //table_partner.setValue("0000002007","PARTN_NUMB");
                   table_partner.setValue("0000100067","PARTN_NUMB");
                   table_partner.setValue(SOLD_NAME,"NAME");  // can be changed
                   table_partner.setValue(SOLD_STREET,"STREET"); // can be changed
                   table_partner.setValue(SOLD_COUNTRY,"COUNTRY");
                   table_partner.setValue(SOLD_POST_CODE,"POSTL_CODE"); // can be changed
                   // Ship to party
                  table_partner.appendRow();
                   table_partner.setRow(2);
                   table_partner.setValue("WE","PARTN_ROLE");
                   table_partner.setValue("0000100067","PARTN_NUMB");
                   table_partner.setValue(SHIP_NAME,"NAME");// can be changed
                   table_partner.setValue(SHIP_STREET,"STREET"); // can be changed
                   table_partner.setValue(SHIP_COUNTRY,"COUNTRY");
                   table_partner.setValue(SHIP_POST_CODE,"POSTL_CODE");// can be changed
                   // Call the remote system
                   client.execute(function);
                   // Print return message
                   JCO.Structure ret = function.getExportParameterList().getStructure("RETURN");
                   System.out.println("BAPI_SALES_ORDER_GETLIST RETURN: " + ret.getString("MESSAGE"));
                   // Get table containing the orders
                   //JCO.Table sales_orders = function.getTableParameterList().getTable("SALES_ORDERS");
                  JCO.Field sales_order = function.getExportParameterList().getField("SALESDOCUMENT");
                   // Print results
                   String so = sales_order.getString();
                   String message = ret.getString("MESSAGE");
                   String message_type = ret.getString("TYPE");
                   if  (message_type.equalsIgnoreCase("E"))  {
                        System.out.println("Error in Sales Order Creation:" + message);
                   else{
                        System.out.println("Sales Order " + so + " Created Succesfully");
                   // Release the client into the pool
                   JCO.releaseClient(client);
              catch (Exception ex) {
                   System.out.println("Caught an exception: \n" + ex);
         //     Retrieves and sales order Create
          public void listSalesOrders()
               try {
                    // Get a function template from the repository
                    IFunctionTemplate ftemplate = repository.getFunctionTemplate("BAPI_SALESORDER_GETLIST");
                    // Create a function from the template
                    JCO.Function function = new JCO.Function(ftemplate);
                    // Get a client from the pool
                    JCO.Client client = JCO.getClient(SID);
                    // Fill in input parameters
                    JCO.ParameterList input = function.getImportParameterList();
                    //input.setValue("0000002007", "CUSTOMER_NUMBER"   );
                    input.setValue(      "3000", "SALES_ORGANIZATION");
                    //input.setValue(         "0", "TRANSACTION_GROUP" );
                    //input.setValue("PO_NUMBER_JAVA01","PURCHASE_ORDER_NUMBER");
                    // Call the remote system
                    client.execute(function);
                    // Print return message
                    JCO.Structure ret = function.getExportParameterList().getStructure("RETURN");
                    System.out.println("BAPI_SALES_ORDER_GETLIST RETURN: " + ret.getString("MESSAGE"));
                    // Get table containing the orders
                    JCO.Table sales_orders = function.getTableParameterList().getTable("SALES_ORDERS");
                    // Print results
                    if (sales_orders.getNumRows() > 0) {
                         // Loop over all rows
                         do {
                             counter++;
                              System.out.println("--" + counter + "--
                              // Loop over all columns in the current row
                              for (JCO.FieldIterator e = sales_orders.fields(); e.hasMoreElements(); ) {
                                   JCO.Field field = e.nextField();
                                   System.out.println(field.getName() + ":\t" + field.getString());
                              }//for
                         } while(sales_orders.nextRow());
                    else {
                         System.out.println("No results found");
                    }//if
                    // Release the client into the pool
                    JCO.releaseClient(client);
               catch (Exception ex) {
                    System.out.println("Caught an exception: \n" + ex);
         public static void main(String[] argv) {
              SalesOrder so = new SalesOrder();
              so.createSalesOrder("PO_NUMBER_JAVA02", "","0000000020000","121-223-2332-1231", "SOFTWARE SYSTEME GMBH-WE", "STREET-SH","US", "53125","SOFTWARE SYSTEME GMBH-WE", "STREET-SH","US", "53125");
              //so.listSalesOrders();     
    >>>>Please if any of SDN users can help in resolving this issue. It will be very helpful to my cousin.

    Before:
    //Populate the item detalis
    table_item.appendRow();
    table_item.setRow(1);
    table_item.setValue("000010","ITM_NUMBER");
    table_item.setValue("AA01","PO_ITM_NO");// can be changed
    table_item.setValue("IAD-SC3000","MATERIAL");
    table_item.setValue(CUSTMAT,"CUST_MAT");// can be changed
    table_item.setValue("20041212","REQ_DATE");// can be changed in yyyymmdd
    table_item.setValue(RQTY,"REQ_QTY");// can be changed Qty * 1000
    table_item.appendRow();
    table_item.setRow(2);
    table_item.setValue("000020","ITM_NUMBER");
    table_item.setValue("AA01","PO_ITM_NO");// can be changed
    table_item.setValue("IAD-SC3000","MATERIAL");
    table_item.setValue(CUSTMAT,"CUST_MAT");// can be changed
    table_item.setValue("20041212","REQ_DATE");// can be changed in yyyymmdd
    table_item.setValue(RQTY,"REQ_QTY");// can be changed Qty * 1000
    Try to add:
    //Populate the item detalis
    table_item.appendRow();
    table_item.setRow(2);
    table_item.setValue("000020","ITM_NUMBER");
    table_item.setValue("AA01","PO_ITM_NO");// can be changed
    table_item.setValue("IAD-SC3000","MATERIAL");
    table_item.setValue(CUSTMAT,"CUST_MAT");// can be changed
    table_item.setValue("20041212","REQ_DATE");// can be changed in yyyymmdd
    table_item.setValue(RQTY,"REQ_QTY");// can be changed Qty * 1000
    table_item.appendRow();
    table_item.setRow(2);
    table_item.setValue("000020","ITM_NUMBER");
    table_item.setValue("AA01","PO_ITM_NO");// can be changed
    table_item.setValue("IAD-SC3000","MATERIAL");
    table_item.setValue(CUSTMAT,"CUST_MAT");// can be changed
    table_item.setValue("20041212","REQ_DATE");// can be changed in yyyymmdd
    table_item.setValue(RQTY,"REQ_QTY");// can be changed Qty * 1000
    Regards.

  • Find Sales order number from IDOC number

    I have a bunch of SO idocs, in status 64. They are then posted and Sales orders are created.
    How can I programatically find the Sales order Number from the Sales Order idoc number once it is in status 53 (other than going to EDIDS and checking if status = '53' and grabbing the 'STAPA2' field there ).

    Look at table EDIDS for sales order idocs and you can see SO number in any of STAPA1/2/3/4 variable for specific message id and message number.

  • CIF: how to "push" a Sales Order item from ERP to SCM via FunctionModule ?

    Hello experts,
    we are implementing a process in ERP (ECC6.0) where we change a sales order item (VBAP- VPZUO) in order to stop SNP (LiveCache) performing the "fcst consumption" for this specific sales order since it is a spezial promotion / trade fair order which does not justify to change the fcst consumption for the entire product.
    We are searching for a function module or any ABAP "handle" of telling the CIF in ERP to "push" a specific sales order item thru to SCM again. We started with an artificial batch input in VA02 / VA32 and changed a non-used text field field in the sales order position and the document save was doing it. I wonder if someone run over same topic and found a better way to get this done with a specific function module or setting a specific trigger in some other ways.
    I was not sure if this is the correct forum - in case someone knows a better match on SDN I'm happy to move it over to the right place.
    Regards
    Thomas

    Hello Thomas,
    You can't really push a Sales Order seperately, and not advisable also as you should not tamper with CIF interface. I can give you another approach.
    You have to identify during CIF that the Sales Order is a special Sales Order. Better have a separate Sales order type for such special Sales Orders. That being the case, I think you can handle your issue by changing the ATP category of the Sales Order during CIF. The standard Order category is BM. You could create a custom category in APO, and during the transfer, you could change the Sales order category to this custom category. APOCF010  EXIT_/SAPAPO/SAPLCIF_SLS_001 exit (Inbound Sales Order in APO) should be helpful for this. You would need to change the ATP category field in IT_SL_REQ table.
    You could then display this "additional" Sales Order in a separate KF in SNP (if you need it) by assigning it a custom category group in SNP planning area which would have only this custom category. For normal SNP planning, normal SNP sales order of category BM would be relevant.
    Please be aware that when you try out things like this, you might need to tweak a lot of SAP standard behaviour at many other places. Things like CCR also need to be tweaked, and also whatever further planning you have to do for this particular Sales Order might also need to be tweaked.
    Thanks - Pawan

  • PRICING Procedure in SAP for an Incomming Sales Order IDOC

    Hi Friends,
    Here is a situation what we have and what we intend to do.
    We would be getting a Sales Order IDOC and when it hits the SAP..it comes with
    -Material, Qty and Price per material
    -Total Freight
    -Total Tax
    i.e the Pricing conditions are not maintained in SAP at all..we would just get the IDOC externally and the SAP needs to read the material, Qty at line item,
    take the total freight as it comes, and total Tax as it comes in the Idoc.
    My thoughts were to have all the Conditons PR00 (ZR00), KF00 (ZF00), UTXJ (ZTXJ) . ZR00 to set as Manual condition. ZF00 as header Freight and Manual condition, ZTXJ as header condition and Manual.
    I therefore was trying to figure out the best way to set the pricing procedure.
    Please let me know if I am on right track if not which is the way I need to set.
    Thank you
    Ravi

    HI Ravi,
    I think your issue is solved now...so for the benefit of SDN members....can you share the solution..as I am also working on the same requirement !!
    Thanks in advance
    Mayank

  • Automatic Sales Order Creation from PO in B1

    Hi,
    I have this scenario. Purchase order is created in SAP B1 (Business One) which triggers automatic Sales Order creation in SAP ECC 6.0.
    The requirement:
    For the combination of PO number and Sold to party there should be only one sales order created.
    The problem:
    Sometimes for the same PO duplicate Sales orders(sometimes 3,4) are getting created in ECC.
    Possible causes:
    Probably no validations in the interface.
    Question:
    1. First of all, is it an SD issue or PI (process integration) issue.
    2. If it is an SD issue, as a functional consultant what / where can we do to prevent this.
    Thanks.
    Edited by: SAP SD_Newbie on Oct 20, 2011 6:59 PM
    Edited by: SAP SD_Newbie on Oct 20, 2011 6:59 PM
    How do I move this to "ERP - Sales and Distribution (SD) General", because this question is not just related to "ERP SD Sales" but SD in general. Isn't there an option for the users to a question from one forum to another.

    1. First of all, is it an SD issue or PI (process integration) issue.
    - May be PI, or SD or both. I am not sure about the integration mechanism/program so I am not able to pinpoint.
    2. If it is an SD issue, as a functional consultant what / where can we do to prevent this.
    In t.code VOV8, go to the sales document type. Select value A in the field, check Purchase order Number. Then go to t.code OVAH, there make the message number V4 115 as error message. This will not allow the creation of the sales order, if the Purchase order number duplicates. I assume in your process, the purchase order number is populated in the PO number field of the sales order overview screen.
    Regards,

  • Error in Sales Order idoc - No appropriate entry found in table ADRT

    Hello SAP Gurus,
    When I am retriggering a sales order idoc I am getting the following error message.
    No appropriate entry found in table ADRT
    How can I resolve this issue.
    Thanks,
    Narayan.

    Hello Lakshmipati,
    I have checked up the customer master. There was no communication method maintained for any of the customers.
    But even then the order idoc is triggered to our XI system.
    For the one that failed I have maintained the communication method and retriggered again. It had the same failure message.
    Any helpful thoughts is highly appreciated.
    Thanks & Regards,
    Narayan.

  • Sales Order creation using SAP NCo 3.0 x64

    Hi,
    I have been trying to create a sales order using the SAP NCo from Visual Studio (C#) and I'm stuck.
    The  code I have used is:
    using System;
    using System.Collections.Generic;
    using System.Linq;
    using System.Text;
    using System.Threading.Tasks;
    using SAP.Middleware.Connector;
    namespace ConsoleApplication2
        class Program : IDestinationConfiguration
            static void Main(string[] args)
                RfcDestinationManager.RegisterDestinationConfiguration(new Program());
                RfcDestination destination = RfcDestinationManager.GetDestination("EHP6");
                try
                    RfcRepository repo = destination.Repository;
                    IRfcFunction salesDoc = repo.CreateFunction("BAPI_SALESORDER_CREATEFROMDAT2");
                    IRfcFunction salesDocCommit = repo.CreateFunction("BAPI_TRANSACTION_COMMIT");
                    IRfcStructure salesHeader = salesDoc.GetStructure("ORDER_HEADER_IN");
                    IRfcTable salesItems = salesDoc.GetTable("ORDER_ITEMS_IN");
                    IRfcTable salesPartners = salesDoc.GetTable("ORDER_PARTNERS");
                    IRfcStructure salesItemsStruct = salesItems.Metadata.LineType.CreateStructure();
                    IRfcStructure salesPartnersStruct = salesPartners.Metadata.LineType.CreateStructure();
                    //Sales Header
                    salesHeader.SetValue("DOC_TYPE", "MOR");
                    salesHeader.SetValue("DOC_DATE", Convert.ToDateTime("2014-06-19"));
                    salesHeader.SetValue("SALES_ORG", "M210");
                    salesHeader.SetValue("DISTR_CHAN", "01");
                    salesHeader.SetValue("DIVISION", "M1");
                    salesHeader.SetValue("CURRENCY", "USD");
                    //Sales Items
                    salesItemsStruct.SetValue("ITM_NUMBER", "000010");
                    salesItemsStruct.SetValue("MATERIAL", "MP_SHEET_22");
                    salesItemsStruct.SetValue("SHORT_TEXT", "Sheet Grade B, BWT 20lb/75gsm");
                    salesItemsStruct.SetValue("PLANT", "M210");              
                    salesItemsStruct.SetValue("TARGET_QTY", "2000");
                    salesItemsStruct.SetValue("TARGET_QU","LBR");
                    salesItemsStruct.SetValue("TARGET_VAL", "11655.67");
                    // Partner
                    salesPartnersStruct.SetValue("PARTN_ROLE", "SP");
                    salesPartnersStruct.SetValue("PARTN_NUMB", "MP-CUST201");
                    RfcSessionManager.BeginContext(destination);
                    salesDoc.Invoke(destination);
                    salesDocCommit.Invoke(destination);
                    RfcSessionManager.EndContext(destination);
                    Console.WriteLine("Sales Order Created!!");
                    Console.ReadLine();
                catch (RfcCommunicationException e)
                    e.ToString();
                    Console.WriteLine(e);
                    Console.ReadLine();
                catch (RfcLogonException e)
                    e.ToString();
                    Console.WriteLine(e);
                    Console.ReadLine();
                catch (RfcAbapRuntimeException e)
                    e.ToString();
                    Console.WriteLine(e);
                    Console.ReadLine();
                catch (RfcAbapBaseException e)
                    e.ToString();
                    Console.WriteLine(e);
                    Console.ReadLine();
            public RfcConfigParameters GetParameters(String destinationName)
                if ("EHP6".Equals(destinationName))
                    RfcConfigParameters parms = new RfcConfigParameters();
                    parms.Add(RfcConfigParameters.AppServerHost, "xx.xxx.xxx.xx");
                    parms.Add(RfcConfigParameters.SystemNumber, "00");
                    parms.Add(RfcConfigParameters.SystemID, "IE6");
                    parms.Add(RfcConfigParameters.User, "user");
                    parms.Add(RfcConfigParameters.Password, "password");
                    parms.Add(RfcConfigParameters.Client, "800");
                    parms.Add(RfcConfigParameters.Language, "EN");               
                    return parms;
                else return null;
    It returns me no error and even displays "Sales Order Created!!" from the try block. But when I check in VBAK, no Sales Order is being created.
    Can somebody help me understand, if I have missed out something or if I'm going wrong somewhere?
    All dependencies have been added correctly, platform being set to x64. No build/run-time errors.

    Hi Sreyan Choudhury
    have you check if you have completed all the mandatory field?
    the partner "SP" is the customer in your system?
    here an example on how I've used this bapi in a webdynpro:
    * Order Header Details
      CLEAR w_order_header_in.
      w_order_header_in-doc_type = zauart.
      w_order_header_in-sales_org = zvkorg.
      w_order_header_in-distr_chan = stru_order_header-distr_chan.
      w_order_header_in-division = 'GN'.
      w_order_header_in-purch_no_c = stru_order_header-purch_no_s.
      w_order_header_in-purch_no_s = stru_order_header-purch_no_s.
      w_order_header_in-sales_grp = zvkgrp.
      w_order_header_in-sales_off = zvkbur.
      w_order_header_in-compl_dlv = stru_order_header-compl_dlv.
      w_order_header_in-req_date_h = stru_order_header-req_date_h.
      CALL FUNCTION 'CONVERSION_EXIT_ALPHA_INPUT'
        EXPORTING
          input  = w_order_items_in-material
        IMPORTING
          output = w_order_items_in-material.
    * Order Partner Details
      CLEAR: i_order_partners,w_order_partners.
      w_order_partners-partn_role = 'AG'.
      w_order_partners-partn_numb = stru_order_partners-partn_numb.
      CALL FUNCTION 'CONVERSION_EXIT_ALPHA_INPUT'
        EXPORTING
          input  = w_order_partners-partn_numb
        IMPORTING
          output = w_order_partners-partn_numb.
      APPEND w_order_partners TO i_order_partners.
    *partener roles
      SELECT * INTO w_agenti FROM zagenti WHERE vkgrp = zvkgrp.
        CLEAR w_order_partners.
        w_order_partners-partn_role = w_agenti-parvw.
        w_order_partners-partn_numb = w_agenti-lifnr.
        CALL FUNCTION 'CONVERSION_EXIT_ALPHA_INPUT'
          EXPORTING
            input  = w_order_partners-partn_numb
          IMPORTING
            output = w_order_partners-partn_numb.
        APPEND w_order_partners TO i_order_partners.
      ENDSELECT.
    * Order Items
      LOOP AT stru_order_items INTO i_order_items.
        CLEAR: w_order_items_in.
        MOVE-CORRESPONDING i_order_items TO w_order_items_in.
        w_order_items_in-store_loc = i_order_items-lgort.
        w_order_items_in-itm_number = sy-tabix * 10.
       w_order_items_in-item_categ = 'TAN'.
       w_order_items_in-ship_point = 'LS00'.
       w_order_items_in-plant = 'DS00'.
        APPEND w_order_items_in TO i_order_items_in.
        w_order_items_inx-itm_number = w_order_items_in-itm_number.
        w_order_items_inx-target_qty = 'X'.
        w_order_items_inx-item_categ = 'X'.
        w_order_items_inx-ship_point = 'X'.
        w_order_items_inx-plant = 'X'.
        IF w_order_items_in-batch IS NOT INITIAL.
          w_order_items_inx-batch = 'X'.
        ENDIF.
        IF w_order_items_in-store_loc IS NOT INITIAL.
          w_order_items_inx-store_loc = 'X'.
        ENDIF.
        APPEND w_order_items_inx TO i_order_items_inx.
        w_order_schedules_in-itm_number = w_order_items_in-itm_number.
        w_order_schedules_in-sched_line = '0001'.
        w_order_schedules_in-req_qty = w_order_items_in-target_qty.
        APPEND w_order_schedules_in TO i_order_schedules_in.
        w_order_schedules_inx-itm_number = w_order_items_in-itm_number.
        w_order_schedules_inx-sched_line = '0001'.
        w_order_schedules_inx-req_qty = 'X'.
        w_order_schedules_inx-updateflag = 'I'.
        APPEND w_order_schedules_inx TO i_order_schedules_inx.
    * Order Condition Details
        IF i_order_items-prriga <> i_order_items-prnet AND
           i_order_items-prriga <> i_order_items-prbase.
          CLEAR: w_order_conditions_in.
          w_order_conditions_in-itm_number = w_order_items_in-itm_number.
          w_order_conditions_in-cond_type = 'ZMAN'. “manual
    price condition
          w_order_conditions_in-cond_value = i_order_items-prriga / 10.
          APPEND w_order_conditions_in TO i_order_conditions_in.
        ENDIF.
        DATA: v_message_riga TYPE string.
    * Get message manager
        DATA: l_current_controller TYPE REF TO if_wd_controller,
              l_message_manager TYPE REF TO if_wd_message_manager.
        l_current_controller ?= wd_this->wd_get_api( ).
        CALL METHOD l_current_controller->get_message_manager
          RECEIVING
            message_manager = l_message_manager.
        IF i_order_items-prriga = 0 AND i_order_items-omaggio = ''.
          CONCATENATE 'Error during the creation '
                      'empty line INTO v_message_riga.
    *    v_message_riga = 'Errore durante la creazione. Riga non
    *valorizzata'.
    *   Report Error message
          CALL METHOD l_message_manager->report_error_message
            EXPORTING
              message_text = v_message_riga.
          i_bloccasalva = 'X'.
        ENDIF.
      ENDLOOP.

Maybe you are looking for

  • Multiple Convert/Dump and Load tasks in a single SSIS package?

    I'd appreciate some input. We have a single data file that has about 1,000,000 rows of data spanning 28 time periods in the columns across each row. The file is too large to import at one time, and so we have created 9 different transformation files

  • Error message on what seems to be a 'black screen of death"?

    I turned on my Mac Mini yesterday and got this error message on one line of text on an otherwise empty black screen "June 29 XX:XX:XX launchd can't exec/bin/sh for single user no such file or directory" (the XX's likely to indicate exact time of boot

  • WRT54GL Disconnecting and other issues

    Purchased this router after having problems with a netgear one. On trying it it worked ok for a small while and then started giving problems. It will not show in wireless network list randomly, then come back for no real apparant reason. It will not

  • Canon 5D III tether to iPad 4 (either cable direct or wifi

    I'm using a Canon 5D III and I would like to RELIABLY transfer photos in real-time to my iPad 4 Retina for proofing/checking the photos.  Either cable-direct or wifi.  I have the latest version of Lightroom and PS CC 2014. Can I do it and how do I do

  • Re: Infinity installation: Engineer appointments b...

    just to let you all know i too orderd bt infinty 2 got a appointment for 24th april 2013 and to be in from 8am to 1pm well i stayed in all day no one called or phoned to explain whats happening or why the delay etc,  the same time come 1pm my phone l