Add Sales Opportunity using DI API

Hello Friends,
    I am trying to add Sales Opportunity using DI API.I want to set Potential amount using DI API So I set MaxLocalTotal but while compiling code its give error.Its Read only.
If I add without potential amount than its gives me error  "Potetial Amout is missing"
What should I do??
My Code is 
               SAPbobsCOM.SalesOpportunities vSOpp;
                vSOpp = (SAPbobsCOM.SalesOpportunities)globals1.oCompany.GetBusinessObject  (SAPbobsCOM.BoObjectTypes.oSalesOpportunities);
                vSOpp.CardCode = txtBPCode.Text;
                if( txtCntctPerCode.Value!="")
                vSOpp.ContactPerson = Convert.ToInt32(txtCntctPerCode.Value);
                vSOpp.OpportunityName = txtOppName.Text;
                vSOpp.SalesPerson = Convert.ToInt32(ddlSEmp.SelectedValue);
               //vSOpp.WeightedSumLC = Convert.ToDouble(txtPotAmt.Text);
                vSOpp.MaxLocalTotal = Convert.ToDouble(txtPotAmt.Text);       
               culture = new CultureInfo("en-US", true);
                currentprovider = CultureInfo.CurrentCulture;
                dt1 = DateTime.ParseExact(txtSDate.Text, "dd/MM/yyyy", culture);
                vSOpp.StartDate = dt1;
  if (vSOpp.Add() != 0)
                    //ResultMessage1.ShowFail("Failed to add a Activity");
                    globals1.oCompany.GetLastError(out nErr, out errMsg);
                    if (0 != nErr)
                        ResultMessage1.ShowFail(globals1.oCompany.GetLastErrorDescription());
                        globals1.oCompany.Disconnect();
                        return;
                else
                    ResultMessage1.ShowSuccess("Activity added Successfully");
Please help me to solved this problem.
Thanks & Regards,
    Swati

Hi folks,
I'm facing the same problem. This issue concerns DI API of SAP Business One 8.8 (my version is SP 00 PL 11) in particular.
I've used the 2007 version so far and even though the MaxLocalTotal field in Sales Opportunity object is read-only, by writing the same value in the field with the same name on the last Opportunity Line I obtain the right value in the header.
In this version of the API, that field seems to be mandatory instead.
Does anyone have any suggestion? Thank you in advance.

Similar Messages

  • Error in add Sales Opportunity with DI API 8.8

    Hi folks,
    I have problems saving a Sales Opportunity by using DI API of SAP Business One 8.8 (my version is SP 00 PL 11).
    I get an error like "10000700 - In 'Potential Amount' field, enter number greater than 0".
    I noticed that the required field I'm trying to set, MaxLocalTotal, is read-only. I've used the 2007 version so far and even though that field is not writable, by writing the same value in the field with the same name on the last Opportunity Line I obtain the right value in the header. In this version of the API, that field seems to be mandatory instead.
    Am I doing something wrong to set Potential Amount in the opportunity?
    Does anyone have any suggestion? Thank you in advance.

    Not even one suggestion or advice? Any help is appreciated. Thanks.

  • Creating Excise Invoice from Sales Delivery using DI API.

    Hi Experts,
    I have been searching a lot for any Business Object for creating Excise Invoice base on Sales Delivery using DI API.. But have not yet found any one.
    I want to create Invoice for excisable items from Sales Delivery using DI API.,for Excisable items we cannot create standalone A/R Invoice . We need to create Excise Invoice also . But How to create Excise Invoice based on Sales Delivery using DI API. Is there any Business Object for that.
    Please suggest me.
    Thanks and Regards,
    Pooja Singh.

    Hi all,
    I have not received any reply for this thread. Does this mean that there is no provision for creating Excise Invoice from Sales Delivery ? Actually I was asked to create sales delivery and then Outgoing Excise Invoice and then Sales Invoice using DI API.
    But I don't find any Business Object for this in SDK ? Is it really not possible to create Outgoing Excise Invoice from Sales Delivery using DI API.? If possible then how?
    Please reply me if anyone has got any idea in this regard.
    Thanks and Regards,
    Pooja Singh.

  • Add Goods Receipt using DI API

    Hi all,
    I want to add a new Goods Receipt using DI API, for each of the lines:
            oBatchReceipt.Lines.SetCurrentLine(1)
            oBatchReceipt.Lines.ItemCode = "ItemA"
            oBatchReceipt.Lines.WarehouseCode = "WH01"
            oBatchReceipt.Lines.Quantity = 1000
    instead of entering the unitcost of the item, i want to enter the line total.
    (unitcost or oBatchReceipt.Lines.Price is commented out)
            'oBatchReceipt.Lines.Price = costUnit
            oBatchReceipt.Lines.LineTotal = 1563
    so, when the Goods Receipt is added, there is no error popped up, but the total of created Goods Receipt is 0 (zero).
    I want to use the LineTotal instead of Price. Using the SBO system UI, user can enter quantity and linetotal and sytem will automatically calculate the price. But using DI API, i dont think it works because someone from forum says that LineTotal is NOT read/write property as written in SDK documentation.
    Anyone knows about this issue?
    Thanks.
    Cheers'
    erwine

    Hi Erwine Sukardy ,
                                   For eg.  you have used  an item  named as  " ItemA". Please go to the "Item Mater Data " . Set the unitprice as you required .Then no need to enter unitprice at line level using DIAPI .
                                If unitprice exists in item master data then . It will automatically calculates the LineTotal.
                          Hope it helps....,
    Best Regards
    V.Rangarajan

  • Issue in creating sales order using process_header API

    Hi all,
    We have a requirement to create sales order using apps adapter in ebiz from SOA suite composite.I used OE_ORDER_PUB.Process_header API to create order header.
    When I pass the inputs and test the service,I get output with return_status='S'. But no record falls at the OE_ORDER_HEADER_ALL table.
    I cant identify where the problem is.Pls suggest me with the things to resolve this issue.
    Thanks,
    goutham

    Hi all,
    We have a requirement to create sales order using apps adapter in ebiz from SOA suite composite.I used OE_ORDER_PUB.Process_header API to create order header.
    When I pass the inputs and test the service,I get output with return_status='S'. But no record falls at the OE_ORDER_HEADER_ALL table.
    I cant identify where the problem is.Pls suggest me with the things to resolve this issue.
    Thanks,
    goutham

  • Can you update Approval Status in Sales order using DI API using SDK

    Hi experts,
    Can we actually update the Approval Status(WddStatus) in Sales order From approved to pending using DI API.
    Thanks,
    John

    Hi John,
    When the sales order is originally created, and at that point pending approval, it is stored as a draft. Once approved, a sales order is created based on the draft.
    In other words, the pending document and the approved document are two entirely separate objects in the database (they use different tables), and in the SDK.
    That means that you can certainly realize your requirement, but you will have to look at it from another perspective. In quasi code:
    Intercept the update event
    Check if any changes were made that warrant another approval round
    If so, duplicate the (adjusted) order, and submit the new order to trigger the new approval round.
    Close or cancel the original order.
    Admittedly this seems a bit silly, but unfortunately the approval process in B1 is still not perfect. As such I recommend that you (also) log on to the SAP Business One Idea Place, (it is free, like the SCN) and vote for any ideas that pertain to your requirement, and/or create an idea of your own.
    Another approach all together could be to instruct users not to make changes to orders, and to use the stored procedure to prevent updates. And allowing users to only submit a new order altogether (they can use the duplicate functionality).
    Regards,
    Johan

  • How to Create RMA Based on Sales order using OE_ORDER_PUB api

    Hi,
    Can any one pls help me how to create a RMA based on the sales order using oe_order_pub.process_order APi.
    Thanks.

    Creating RMA is very similar to creating an Order. You need to make sure you're passing the correct order_type, line_type which'll be setup as 'RETURN' (or 'MIXED') category in transaction type definition.
    For the API to automatically create a reference on your RMA lines to the original Order lines, you need to pass the following
    l_line_tbl (l_line_tbl.COUNT).return_reason_code := 'RETURN'; -- Mandatory for RMA
    l_line_tbl (l_line_tbl.COUNT).reference_line_id := v_ref_line_id; -- Original order line_id
    l_line_tbl (l_line_tbl.COUNT).reference_header_id := v_ref_header_id; -- Original order header_id
    l_line_tbl (l_line_tbl.COUNT).return_context := 'ORDER';
    l_line_tbl (l_line_tbl.COUNT).return_attribute1 := v_ref_header_id; -- Original order header_id
    l_line_tbl (l_line_tbl.COUNT).return_attribute2 := v_ref_line_id; -- Original order line_id
    Once the RMA gets created, query the order and navigate to Lines>Returns tab. You can see the original order number and line number.
    Thanks
    Gopal

  • How to create the service lines in a sales order using Process_order API

    Hi ,
    I have to create the service lines in a Config to order using process Order API. When i am trying to create a sercvice line , it is comming as new line all together. but i need that one to happen in the configuration itself after the option item but not like standalone line.
    what are the manditory fields for service lines to create using Process_order API.
    Apprciate your help on this.
    Thanks
    Rags

    Moderator message - Please do some analysis before posting here - thread locked
    Rob

  • Issue in creating sales order using process_header API (web service)

    Hi All,
    I am trying to create sales order header using web service call to OE_ORDER_PUB.Process_header API.
    When I pass the inputs and test the service,I get output with return_status='S'. But no record falls at the OE_ORDER_HEADER_ALL table.
    I cant identify where the problem is.Is there any commit missing? Pls help me resolve this issue.
    Thanks,
    Vinoth

    Hi All,
    I am trying to create sales order header using web service call to OE_ORDER_PUB.Process_header API.
    When I pass the inputs and test the service,I get output with return_status='S'. But no record falls at the OE_ORDER_HEADER_ALL table.
    I cant identify where the problem is.Is there any commit missing? Pls help me resolve this issue.
    Thanks,
    Vinoth

  • Rounding in Sales Order using DI-API

    Hello,
    We have an add-on which creates salers orders from emails. Upto 2005 B, this has been working perfectly. But after upgrading to 2007 B, the rounding has stopped taking place.
    So, if the document total comes to INR 554.32 - it remains as it is - whereas it should be rounded to 554.00. We have checked all options, and have also searched for notes, and help on these forums. But have not find any resolution.
    We have come to understand that this is a problem with DI-API in new version, and should be corrected in next patch release.
    Thanks & Regards,
    Rahul Jain

    Hi Rahul,
    Taking into consideration the new fact, I appears the DI API is not enforcing the system settings, which should not happen.
    Have you applied the latest PL available? If not, check if there is a later PL that correct that problem and also search the SAP Notes to see if someone else has detected the same problem.
    Regards,
    Vítor Vieira

  • Create sales order using  IBE_Quote_W1_PVT.SUBMITQUOTEWRAPPER

    Hi,
    I am trying to create an sales order using following api. which creates cart from shopping cart.
    SET serveroutput ON
    DECLARE
    P_API_VERSION_NUMBER NUMBER;
    P_INIT_MSG_LIST VARCHAR2(200);
    P_COMMIT VARCHAR2(200);
    X_RETURN_STATUS VARCHAR2(200);
    X_MSG_COUNT NUMBER;
    X_MSG_DATA VARCHAR2(200);
    P_QUOTE_HEADERID NUMBER;
    P_LAST_UPDATE_DATE DATE;
    P_SHAREE_NUMBER NUMBER;
    P_SHAREE_PARTY_ID NUMBER;
    P_SHAREE_ACCOUNT_ID NUMBER;
    P_SC_BOOK_FLAG VARCHAR2(200);
    P_SC_RESERVE_FLAG VARCHAR2(200);
    P_SC_CALCULATE_PRICE VARCHAR2(200);
    P_SC_SERVER_ID NUMBER;
    P_SC_CC_BY_FAX VARCHAR2(200);
    P_CUSTOMER_COMMENTS VARCHAR2(200);
    P_REASON_CODE VARCHAR2(200);
    P_SALESREP_EMAIL_ID VARCHAR2(200);
    P_MINISITE_ID NUMBER;
    X_LAST_UPDATE_DATE DATE;
    X_ORDER_NUMBER NUMBER;
    X_ORDER_HEADER_ID NUMBER;
    X_ORDER_REQUEST_ID NUMBER;
    X_CONTRACT_ID NUMBER;
    X_STATUS VARCHAR2(200);
    X_HOLD_FLAG VARCHAR2(200);
    BEGIN
    P_API_VERSION_NUMBER := 1;
    P_INIT_MSG_LIST := FND_API.G_TRUE;
    P_COMMIT := FND_API.G_FALSE;
    P_QUOTE_HEADERID := 18534;
    P_LAST_UPDATE_DATE := to_date('2012-10-01 04:33:45','YYYY-MM-DD HH24:MI:SS');
    P_SHAREE_NUMBER := FND_API.G_MISS_NUM ;
    P_SHAREE_PARTY_ID := FND_API.G_MISS_NUM ;
    P_SHAREE_ACCOUNT_ID := FND_API.G_MISS_NUM ;
    P_SC_BOOK_FLAG := FND_API.G_MISS_CHAR;
    P_SC_RESERVE_FLAG := FND_API.G_FALSE;
    P_SC_CALCULATE_PRICE := FND_API.G_FALSE;
    P_SC_SERVER_ID := -1;
    P_SC_CC_BY_FAX := FND_API.G_FALSE;
    P_CUSTOMER_COMMENTS := FND_API.G_MISS_CHAR;
    P_REASON_CODE := FND_API.G_MISS_CHAR;
    P_SALESREP_EMAIL_ID := FND_API.G_MISS_CHAR;
    P_MINISITE_ID := 10660;
    IBE_Quote_W1_PVT.SUBMITQUOTEWRAPPER(
    P_API_VERSION_NUMBER => P_API_VERSION_NUMBER,
    P_INIT_MSG_LIST => P_INIT_MSG_LIST,
    P_COMMIT => P_COMMIT,
    X_RETURN_STATUS => X_RETURN_STATUS,
    X_MSG_COUNT => X_MSG_COUNT,
    X_MSG_DATA => X_MSG_DATA,
    P_QUOTE_HEADERID => P_QUOTE_HEADERID,
    P_LAST_UPDATE_DATE => P_LAST_UPDATE_DATE,
    P_SHAREE_NUMBER => P_SHAREE_NUMBER,
    P_SHAREE_PARTY_ID => P_SHAREE_PARTY_ID,
    P_SHAREE_ACCOUNT_ID => P_SHAREE_ACCOUNT_ID,
    P_SC_BOOK_FLAG => P_SC_BOOK_FLAG,
    P_SC_RESERVE_FLAG => P_SC_RESERVE_FLAG,
    P_SC_CALCULATE_PRICE => P_SC_CALCULATE_PRICE,
    P_SC_SERVER_ID => P_SC_SERVER_ID,
    P_SC_CC_BY_FAX => P_SC_CC_BY_FAX,
    P_CUSTOMER_COMMENTS => P_CUSTOMER_COMMENTS,
    P_REASON_CODE => P_REASON_CODE,
    P_SALESREP_EMAIL_ID => P_SALESREP_EMAIL_ID,
    P_MINISITE_ID => P_MINISITE_ID,
    X_LAST_UPDATE_DATE => X_LAST_UPDATE_DATE,
    X_ORDER_NUMBER => X_ORDER_NUMBER,
    X_ORDER_HEADER_ID => X_ORDER_HEADER_ID,
    X_ORDER_REQUEST_ID => X_ORDER_REQUEST_ID,
    X_CONTRACT_ID => X_CONTRACT_ID,
    X_STATUS => X_STATUS,
    X_HOLD_FLAG => X_HOLD_FLAG
    DBMS_OUTPUT.PUT_LINE('X_RETURN_STATUS = ' || X_RETURN_STATUS);
    DBMS_OUTPUT.PUT_LINE('X_MSG_COUNT = ' || X_MSG_COUNT);
    DBMS_OUTPUT.PUT_LINE('X_MSG_DATA = ' || X_MSG_DATA);
    DBMS_OUTPUT.PUT_LINE('X_LAST_UPDATE_DATE = ' || X_LAST_UPDATE_DATE);
    DBMS_OUTPUT.PUT_LINE('X_ORDER_NUMBER = ' || X_ORDER_NUMBER);
    DBMS_OUTPUT.PUT_LINE('X_ORDER_HEADER_ID = ' || X_ORDER_HEADER_ID);
    DBMS_OUTPUT.PUT_LINE('X_ORDER_REQUEST_ID = ' || X_ORDER_REQUEST_ID);
    DBMS_OUTPUT.PUT_LINE('X_CONTRACT_ID = ' || X_CONTRACT_ID);
    DBMS_OUTPUT.PUT_LINE('X_STATUS = ' || X_STATUS);
    DBMS_OUTPUT.PUT_LINE('X_HOLD_FLAG = ' || X_HOLD_FLAG);
    END;
    When i use this from a OA_HTML jsp the sales order is created . But when i use it from the sql developer
    i got following error
    X_RETURN_STATUS = E
    X_MSG_COUNT = 1
    X_MSG_DATA = You do not have access to this cart.
    X_LAST_UPDATE_DATE =
    X_ORDER_NUMBER = 9.990000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000E+125
    X_ORDER_HEADER_ID = 9.990000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000E+125
    X_ORDER_REQUEST_ID = 9.990000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000E+125
    X_CONTRACT_ID = 9.990000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000E+125
    X_STATUS =
    I checked logs for both .
    For working one log is ie. using jsp
    01-OCT-2012:01:24:46 IBE IBE_UTIL.enable_debug_new p_check_profile is N
    01-OCT-2012:01:24:46 IBE IBE_UTIL.enable_debug_new p_check_profile is N
    01-OCT-2012:01:24:46 IBE Begin validate_user_update10/01/2012:01:24:46
    01-OCT-2012:01:24:46 IBE Incoming party_id is 423832
    01-OCT-2012:01:24:46 IBE Incoming cust_account_id is 140757
    01-OCT-2012:01:24:46 IBE Incoming quote_header_id is 18529
    01-OCT-2012:01:24:46 IBE User id obtained from environment is: -1
    01-OCT-2012:01:24:46 IBE p_save_type is :6
    01-OCT-2012:01:24:46 IBE Entered Validation...T
    01-OCT-2012:01:24:46 IBE no sharee number
    01-OCT-2012:01:24:46 IBE quote_source_code of cart passed in=IStore Account
    01-OCT-2012:01:24:46 IBE In validating Owner flow: 423832,140757 10/01/2012:01:24:46
    01-OCT-2012:01:24:46 IBE Validate_user_update: Before Last update date validation,p_last_update_date= 01-10-12
    01-OCT-2012:01:24:46 IBE Validate_user_update: Last update date validation START
    01-OCT-2012:01:24:46 IBE Validate_user_update: l_last_update_date=
    01-OCT-2012:01:24:46 IBE Validate_user_update: p_last_update_date=10/01/2012:00:22:07
    01-OCT-2012:01:24:46 IBE Validate_user_update: Last update date validation END
    01-OCT-2012:01:24:46 IBE Before calling validate_quote10/01/2012:01:24:46
    01-OCT-2012:01:24:46 IBE Begin Validate_quote10/01/2012:01:24:46
    01-OCT-2012:01:24:46 IBE Validate_quote: Validation for one-click start
    01-OCT-2012:01:24:46 IBE End validate_quote10/01/2012:01:24:46
    01-OCT-2012:01:24:46 IBE End validate_user_update10/01/2012:01:24:46
    but for the failure it is.
    01-OCT-2012:01:20:53 IBE IBE_UTIL.enable_debug_new p_check_profile is N
    01-OCT-2012:01:20:53 IBE IBE_UTIL.enable_debug_new p_check_profile is N
    01-OCT-2012:01:20:53 IBE Begin validate_user_update10/01/2012:01:20:53
    01-OCT-2012:01:20:53 IBE Incoming party_id is 9.990000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000E+125
    01-OCT-2012:01:20:53 IBE Incoming cust_account_id is 9.990000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000E+125
    01-OCT-2012:01:20:53 IBE Incoming quote_header_id is 18529
    01-OCT-2012:01:20:53 IBE User id obtained from environment is: -1
    01-OCT-2012:01:20:53 IBE p_save_type is :6
    01-OCT-2012:01:20:53 IBE Entered Validation...T
    01-OCT-2012:01:20:53 IBE no sharee number
    01-OCT-2012:01:20:53 IBE quote_source_code of cart passed in=IStore Account
    01-OCT-2012:01:20:53 IBE Owner flow with env. userid: 10/01/2012:01:20:53
    01-OCT-2012:01:20:53 IBE partyId::quotehdrId(9.990000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000E+125,18529)
    01-OCT-2012:01:20:53 IBE End:Expected exception:IBE_Quote_Misc_pvt.validate_user_update
    From this u can see that party id and account is fetched when using jsp. but direct running of procedure not getting these values.
    is there sql api running when accessing through jsp . so that these values are got from session.
    Thanks
    Mark

    Hi,
    I have passed that too . still getting same error.
    IBE_Quote_W1_PVT.SUBMITQUOTEWRAPPER calls IBE_Quote_Checkout_Pvt.submitQuote
    which calls another package
    PROCEDURE Validate_User_Update(
    p_api_version_number IN NUMBER := 1.0
    ,p_init_msg_list IN VARCHAR2 := FND_API.G_FALSE
    ,p_quote_header_id IN NUMBER
    ,p_party_id IN NUMBER := FND_API.G_MISS_NUM
    ,p_cust_account_id IN NUMBER := FND_API.G_MISS_NUM
    ,p_quote_retrieval_number IN NUMBER := FND_API.G_MISS_NUM
    ,p_validate_user IN VARCHAR2 := FND_API.G_FALSE
    ,p_privilege_type_code IN VARCHAR2 := 'F'
    ,p_save_type IN NUMBER := FND_API.G_MISS_NUM
    ,p_last_update_date IN DATE := FND_API.G_MISS_DATE
    ,x_return_status OUT NOCOPY VARCHAR2
    ,x_msg_count OUT NOCOPY NUMBER
    ,x_msg_data OUT NOCOPY VARCHAR2)
    in it like this
    IBE_Quote_Misc_pvt.Validate_User_Update(
         p_init_msg_list => FND_API.G_TRUE
         ,p_quote_header_id => p_quote_Header_Id
         ,p_quote_retrieval_number => p_sharee_number
         ,p_validate_user     => FND_API.G_TRUE
         ,p_privilege_type_code => 'A'
    ,p_save_type => PLACE_ORDER
    ,p_last_update_date => p_last_update_date
    ,x_return_status => x_return_status
    ,x_msg_count => x_msg_count
    ,x_msg_data => x_msg_data
    from this u can see that there no value passed for party id and account id .
    Thanks
    Mark

  • Freight charges using oe_orde_pub api

    freight charges using oe_orde_pub api.

    Can you please tell me how to load Charges while creating the Sales Orders using oe_order_pub API.
    --Prasanth                                                                                                                                                                                                                               

  • Pick Release using backend API

    Hello All ,
    I am trying to pick release one sales order using standard API WSH_DELIVERIES_PUB .
    I am using the below block.
    DECLARE
    -- Standard Parameters.
    p_api_version NUMBER;
    p_init_msg_list VARCHAR2(30);
    p_commit VARCHAR2(30);
    --Parameters for WSH_DELIVERIES_PUB.Delivery_Action.
    p_action_code VARCHAR2(15);
    p_delivery_id NUMBER;
    p_delivery_name VARCHAR2(30);
    p_asg_trip_id NUMBER;
    p_asg_trip_name VARCHAR2(30);
    p_asg_pickup_stop_id NUMBER;
    p_asg_pickup_loc_id NUMBER;
    p_asg_pickup_loc_code VARCHAR2(30);
    p_asg_pickup_arr_date DATE;
    p_asg_pickup_dep_date DATE;
    p_asg_dropoff_stop_id NUMBER;
    p_asg_dropoff_loc_id NUMBER;
    p_asg_dropoff_loc_code VARCHAR2(30);
    p_asg_dropoff_arr_date DATE;
    p_asg_dropoff_dep_date DATE;
    p_sc_action_flag VARCHAR2(10);
    p_sc_close_trip_flag VARCHAR2(10);
    p_sc_create_bol_flag VARCHAR2(10);
    p_sc_stage_del_flag VARCHAR2(10);
    p_sc_trip_ship_method VARCHAR2(30);
    p_sc_actual_dep_date VARCHAR2(30);
    p_sc_report_set_id NUMBER;
    p_sc_report_set_name VARCHAR2(60);
    p_wv_override_flag VARCHAR2(10);
    x_trip_id VARCHAR2(30);
    x_trip_name VARCHAR2(30);
    -- outparameters
    x_return_status VARCHAR2(10);
    x_msg_count NUMBER;
    x_msg_data VARCHAR2(2000);
    x_msg_details VARCHAR2(3000);
    x_msg_summary VARCHAR2(3000);
    -- Handle exceptions
    fail_api EXCEPTION;
    BEGIN
    -- Initialize return status
    x_return_status := WSH_UTIL_CORE.G_RET_STS_SUCCESS;
    -- Call this procedure to initialize applications parameters.
    FND_GLOBAL.APPS_INITIALIZE(
    user_id => 7830
    , resp_id => 51460
    , resp_appl_id => 660);
    -- Values for WSH_DELIVERIES_PUB.delivery_action
    p_action_code := 'PICK-RELEASE'; -- Releases Lines related to a delivery
    p_delivery_id := 16092; -- delivery ID that action is performed on
    -- Call to WSH_DELIVERIES_PUB.Delivery_Action.
    WSH_DELIVERIES_PUB.Delivery_Action(
    p_api_version_number => 1.0,
    p_init_msg_list => P_init_msg_list,
    x_return_status => x_return_status,
    x_msg_count => x_msg_count,
    x_msg_data => x_msg_data,
    p_action_code => p_action_code,
    p_delivery_id => p_delivery_id,
    p_delivery_name => p_delivery_name,
    p_asg_trip_id => p_asg_trip_id,
    p_asg_trip_name => p_asg_trip_name,
    p_asg_pickup_stop_id => p_asg_pickup_stop_id,
    p_asg_pickup_loc_id => p_asg_pickup_loc_id,
    p_asg_pickup_loc_code => p_asg_pickup_loc_code,
    p_asg_pickup_arr_date => p_asg_pickup_arr_date,
    p_asg_pickup_dep_date => p_asg_pickup_dep_date,
    p_asg_dropoff_stop_id => p_asg_dropoff_stop_id,
    p_asg_dropoff_loc_id => p_asg_dropoff_loc_id,
    p_asg_dropoff_loc_code => p_asg_dropoff_loc_code,
    p_asg_dropoff_arr_date => p_asg_dropoff_arr_date,
    p_asg_dropoff_dep_date => p_asg_dropoff_dep_date,
    p_sc_action_flag => p_sc_action_flag,
    p_sc_close_trip_flag => p_sc_close_trip_flag,
    p_sc_create_bol_flag => p_sc_create_bol_flag,
    p_sc_stage_del_flag => p_sc_stage_del_flag,
    p_sc_trip_ship_method => p_sc_trip_ship_method,
    p_sc_actual_dep_date => p_sc_actual_dep_date,
    p_sc_report_set_id => p_sc_report_set_id,
    p_sc_report_set_name => p_sc_report_set_name,
    p_wv_override_flag => p_wv_override_flag,
    x_trip_id => x_trip_id,
    x_trip_name => x_trip_name);
    if (x_return_status <> WSH_UTIL_CORE.G_RET_STS_SUCCESS) then
    raise fail_api;
    else
    dbms_output.put_line('The delivery '||p_delivery_id || ' is successfully pick released');
    end if;
    EXCEPTION
    when fail_api then
    WSH_UTIL_CORE.get_messages('Y', x_msg_summary, x_msg_details,x_msg_count);
    if x_msg_count > 1 then
    x_msg_data := x_msg_summary || x_msg_details;
    Dbms_output.put_line('Message Data : '||x_msg_data);
    else
    x_msg_data := x_msg_summary;
    Dbms_output.put_line('Message Data : '||x_msg_data);
    end if;
    END;
    However I am geting the following error.
    Message Data : Error: Number of concurrent requests launched successfully: 0. Number of requests that failed: 1.Error: Launching Pick Release failed for Delivery 16092.
    I am able to do Pick Release from front end .
    Regards,

    Hi there,
    I need to create custom Pick Release code as part of whole new Shipping Module.
    Can you share with me the backend code you have for 'Pick Release'?
    I'll appreciate that very much.
    And also please let me know the release level of your Oracle Applications.
    Thanks.
    Bobby

  • How to add Documents object faster(DI-API)

    Hello,
    I investigated the time concerning adding to Order Document using DI-API.
    Result,339sec per 300 document(for each document has
    4 items ,program was not use Start/End transaction).
    This result is not so bad, but i wish faster time.
    Please suggest faster way to add Documents object using
    DI-API.
    My source code is below.
    vINV = vCompany.GetBusinessObject(SAPbobsCOM.BoObjectTypes.oOders)
    For I = 1 To 300
    vINV.CardCode = "test"
    vINV.Docdate = "2005/12/31"
    vINV.DocDueDate = "2005/12/31"
    vINV.NumAtCard = "test"
       For J = 0 To 3
         vINV.Lines.ItemCode = "test"
         vINV.Lines.Quantity = 1
         vINV.Lines.Price = 400
         if J <> 3 Then
           vINV.Lines.add()
         End If 
        Next J
       RetVal = vINV.Add
    Next I

    Hi Jiro,
    I have never worked with this before, but maybe you can investigate using the DI Server. Search the forum for the DI Server. Herewith an extract from the DI Server help file:
    <i>SAP Business One - Data Interface Server (DI Server) is a Component Object Model (COM) service running on a server that enables multiple clients to access and manipulate SAP Business One company database, using SOAP version 1.1 messages.
    The DI Server uses the DI core to enable the same functionality provided by the DI API with the following advantages:
    - Server architecture.
    - <b>Improved performance.</b>
    - Connection pooling mechanism.
    - Generic interface.
    The DI Server operates with SAP Business One application version 2004.</i>
    Hope it helps,
    Adele

  • Can you add a Purchase Order with Sales Order as its Base Type using DI-API

    Is it possible to set the basetype on a PurchaseOrder document line to 17 to create a document as you would using the Procurement Confirmation Wizard in the UI?
    I am using 8.81 SP00 PL09.

    Anyone?
    We already have code to automatically generate Sales Orders using the DI-API, and if we could automate the create of the Purchase Orders as well, it would save a lot of end-user time.
    We would like to do it with the Base/Target references set so that end users can navigate between them in the UI.
    You can do it with the Procurement Confirmation Wizard, and I would like to know if it is possible to replicate this functionality through the DI-API or if I should move forward by just creating the Purchase Orders without reference to the Sales Order and using a UDF to tie them together.

Maybe you are looking for

  • Newie Mail server and running other services

    We have a small office network of 6 macs that connect to a Panther server, this server provides DNS and file sharing and thats about it a Filemaker Sever and Retrospect Server. I doesn't suffer from heavy use I have been using a a separate mac to run

  • Would like to "confirm exit" before ApplicationMgr_OnExitApplication is called...

    Hello all, I am using TS3.5 with CVI8.0.1 and the "full-featured" CVI operator interface that ships with TS3.5... I would like to force the user to have to answer a confirm pop-up prior to being able to exit the application before the "ApplicationMgr

  • Attaching page break to a paragraph style. Can I?

    I know that we can set a paragraph to start on the next, left or right page, but is it possible to make a paragraph style that makes that para. the last one on the page? So I want the page break function attached to a style. thanks jon

  • Portal eventing between WD java and BSP popup

    Hi guys, I have a WebDynpro application that opens a BSP popup like that : WDPortalNavigation.navigateAbsolute(           wdContext.currentURLElement().getEvaluationURL(),           WDPortalNavigationMode.SHOW_EXTERNAL,           "directories=no loca

  • Purchasing document without material master

    Hi All , I was reading one document (MM-IM) .. there it is mentioned that "The purchasing department can also order materials or services for which no material master record is defined. These are usually materials or services that are only purchased