Add invoice from xml -- wrong vatsum -- wrong discount -- wrong doctotal

hi,
i save my invoice as a draft, save this draft as xml and then add my invoice.
The way until xml goes fine. But when i add the invoice the systems calculates wrong vatsums.In due to that there will be a discount on the document and a wrong doctotal.
When i adding my draft manually as invoice everything works well. Is this a bug? Does anybody know how to solve it?
        oInvoice = moSBOCompany.GetBusinessObjectFromXML(sOLDTAXdraftFilename, 0)
        oInvoice.DocumentsOwner = moSBOCompany.UserSignature  'empID
        RetVal = oInvoice.Add
best regards
Markus

Hi Markus,
Have you checked the information in the Xml file is correct?
Have you tried to create the same invoice with DI API without using xml?
If you are sure you are doing the same thing and the results are not the same please open a message for support, they will investigate it.
Regards
Trinidad.

Similar Messages

  • Pls Help me with steps to add data from xml file to SAP B1 through B1iSN.

    Pls Help me with steps to add data from xml file to SAP B1 through B1iSN. I  am getting stuck in xsl transformation. not able to understand where the mapping code needs to be added.
    Pls explain me the steps for adding data from xml to B1 quotation step by step.
    thanks and regards
    Priya

    Hi,
    Have you checked this: https://sap.na.pgiconnect.com/p45508295/?launcher=false&fcsContent=true&pbMode=normal ?
    Thanks,
    Gordon

  • Unable to add Invoice from a sales order draft.

    Hi all,
    I have a customer who is trying to add an A/R Invoice from a sales order draft and is receiving this error, "applied amount cannot be negative in the base document [Message 439-182]"
    If anyone has seen this before or has any suggestions that would be great.
    Best Regards,
    Jeff Haldeman
    Support One

    Hi Jeff,
    Can you also let us know what where the contents in Sales Order and the resultant AR Invoice?
    The Quantity , Price and the Total
    Regards,
    Jitin
    SAP Business One Forum Team

  • How to add bookmarks from .xml file?

    I switched from a PC to an iMac and i'm trying to set up the Safari browser. I was using MSN explorer as my default. I saved the .xml file where all my bookmarks were stored. Is there a way I can import the .xml file so all my bookmarks can load?

    hi,
    check out the following links
    Check this blog to extract from XML:
    /people/kamaljeet.kharbanda/blog/2005/09/16/xi-bi-integration
    http://help.sap.com/saphelp_nw04/helpdata/en/fe/65d03b3f34d172e10000000a11402f/frameset.htm
    Check thi link for Extract from any DB:
    http://help.sap.com/saphelp_nw04s/helpdata/en/58/54f9c1562d104c9465dabd816f3f24/content.htm
    regards
    harikrishna N

  • Add Invoice from Purchase Order

    Hi experts,
    I add the Button in Purchase order .and bind the Vendor codes and items, qty, price in matrix(Purchase order matrix) . Now i want to add the Invoice separately  for all vendors who are exist in row level when i click the userdefined button in Purchase order (I need not to open a Invoice). How is it possible
    With Best Regards,
    M.Thippa Reddy

    Hi Vassu,
    Thanks for your reply. I use the following code for adding the invoice but i getting error"-5002 Chooseb BP is not a custome [OINV.Cardcode]{Line:1], "V1010"
    Please rectify me i am done any mistake.
    Dim RetVal As Long
            Dim ErrCode As Long
            Dim ErrMsg As String
            'Create the Documents object
            Dim vInvoice As SAPbobsCOM.Documents
            vInvoice = oCompany.GetBusinessObject(SAPbobsCOM.BoObjectTypes.oInvoices)
            'Set values to the fields
            vInvoice.Series = 0
            vInvoice.CardCode = "V1010"
            'vInvoice.HandWritten = "No"
            vInvoice.DocNum = 84
            vInvoice.PaymentGroupCode = "-1"
            vInvoice.DocDate = System.DateTime.Today.Date
            vInvoice.Lines.ItemCode = "A00001"
            '  vInvoice.Lines.ItemDescription = "Banana"
            vInvoice.Lines.TaxCode = "NY"
            vInvoice.Lines.Quantity = 50
            'vInvoice.Lines.DiscountPercent = 10
            vInvoice.Lines.UnitPrice = 5.0
            vInvoice.Lines.Add()
            'Add the Invoice
            RetVal = vInvoice.Add
            'Check the result
            If RetVal <> 0 Then
                oCompany.GetLastError(ErrCode, ErrMsg)
                MsgBox(ErrCode & " " & ErrMsg)
            End If
    Regards,
    M.Thippa Reddy

  • Internal Error when adding Invoice from DI-API

    Hello All,
    I am trying to add an invoice using DI-API. I hv populated the object using XML and than adding it. Upon adding the error Internal Error (-10) is coming. I hv checked everything but am certainly missing something. Following is the XML of the invoice and the code to add it
    <?xml version="1.0" encoding="utf-16" ?>
    <BOM>
      <BO>
        <AdmInfo>
          <Object>13</Object>
          <Version>1</Version>
        </AdmInfo>
        <OINV>
          <row>
            <U_EntryId>1</U_EntryId>
            <DocType>I</DocType>
            <DocDate>20110923</DocDate>
            <DocDueDate>20111023</DocDueDate>
            <CardCode>JM0004</CardCode>
            <CardName>GAYAN BHARTI</CardName>
            <NumAtCard></NumAtCard>
            <DiscPrcnt>0.000000</DiscPrcnt>
            <DocTotal>755.000000</DocTotal>
            <Comments></Comments>
            <U_BranchTrans>1</U_BranchTrans>
            <SlpCode>-1</SlpCode>
            <IsICT>N</IsICT>
            <Series>40</Series>
            <TaxDate>20110923</TaxDate>
            <TrackNo></TrackNo>
            <SeqCode>0</SeqCode>
            <U_SlpName></U_SlpName>
            <U_WebCreated>N</U_WebCreated>
            <U_Territory></U_Territory>
            <U_InvType>C</U_InvType>
          </row>
        </OINV>
        <INV1>
          <row>
            <ItemCode>A003</ItemCode>
            <Dscription></Dscription>
            <Quantity>5.000000</Quantity>
            <DiscPrcnt>0.000000</DiscPrcnt>
            <WhsCode>JSP-FG</WhsCode>
            <PriceBefDi>11.000000</PriceBefDi>
            <TaxCode>NonTax</TaxCode>
            <U_WebCreated>N</U_WebCreated>
            <U_RetQty></U_RetQty>
            <U_SaleQty></U_SaleQty>
            <U_LineType>S</U_LineType>
          </row>
          <row>
            <ItemCode>A005</ItemCode>
            <Dscription>Ace Visual Dictonary 2</Dscription>
            <Quantity>10.000000</Quantity>
            <DiscPrcnt>0.000000</DiscPrcnt>
            <WhsCode>JSP-FG</WhsCode>
            <PriceBefDi>70.000000</PriceBefDi>
            <TaxCode>NonTax</TaxCode>
            <U_WebCreated>N</U_WebCreated>
            <U_RetQty></U_RetQty>
            <U_SaleQty></U_SaleQty>
            <U_LineType>S</U_LineType>
          </row>
        </INV1>
      </BO>
    </BOM>
    Program Code to add
                Dim oSapObject As SAPbobsCOM.Documents
                oCompany.XMLAsString = True
                oSapObject = oCompany.GetBusinessObjectFromXML(Body, 0)
                If oSapObject.Add <> 0 Then
                    Throw New Exception(oCompany.GetLastErrorDescription & " [" & oCompany.GetLastErrorCode & "]")
                End If
    Any help would be greatly appreciated. This is sort of urgent and needs to be done immediately.
    Regards,
    Rahul Jain
    PS: The error is coming on oSapObject.Add - it is able to read the invoice from XML, the error comes when trying to add it. All relevant values mentioned in XML are present in the database, and I am able to add an Invoice from the UI.
    Edited by: Rahul Jain on Sep 24, 2011 1:29 PM

    I realize this might not be to much help but everytime I have ever gotten an internal error code it has always turned out to be a SQL error. For instance there could be something in transaction notification that doesnt jive with your submission or something along those lines. Perhaps you could try a more simplified invoice as a test such as just send one item with a price and no UDFs .
    Sorry if that is not much help.

  • Trying to add album from iphoto into idvd slideshow.  Not all photos are loading.  Message "creating thumbnail images...(31 remaining).  Been there a long time.  What is wrong?

    trying to add album from iphoto into idvd slideshow.  Not all photos are loading.  Message "creating thumbnail images...(31 remaining).  Been there a long time.  What is wrong?

    Open your iPhoto Library, go to that particular album and verify that you can view the full sized version of each image by double clicking on them.  Report back with the results.
    OT

  • Oracle XML Gateway- Mapping XML to Oracle Apps API - Wrong Number or types

    XML GATEWAY INBOUND – CALLING AN API (PL/SQL record type IN variable) TO INSERT THE DATA INTO SAMPLE TABLE
    Hi,
    I am using XML Gateway to push data into Oracle Apps using a procedure call with “Record Type” as the parameter. I am getting a “wrong number” or types of arguments mismatch error inspite of following the process described in the Oracle XML Gateway User’s Guide
    Steps followed:
    DB
    1. I Created a sample table XX_CUST_HIST(ID NUMBER, ACCOUNT_NAME VARCHAR2(50), FIRST_NAME VARCHAR2(50), LAST_NAME VARCHAR2(50), TITLE VARCHAR2(50))
    2. I then Created a package ‘XX_XML_DEMO_API’ in which we have defined a record type and a procedure.
    3. The Record type ‘customerRecordType’ holds account_name , first_name, last_name and the title.
    4. The Procedure ‘insert_customer_r’ takes 2 IN arguments :
    1. p_ id number
    2. p_customer customerRecordType
    5. The procedure will insert the values into xx_cust_hist table
    p_id -> id
    p_customer.account_name -> account_name
    p_customer.first_name -> first_name
    p_customer.last_name -> last_name
    p_customer.title -> title
    Now I need to call the procedure ‘XX_XML_DEMO_API . insert_customer_r’ from XML gateway.
    Following are the steps to call the procedure:
    [1] Create DTD
    ELEMENT NEW_CUSTOMER_APIR (DATAAREA)
    ELEMENT DATAAREA (CUSTOMER_DATA)
    ELEMENT CUSTOMER_DATA (ID, CUSTOMER_RECORD)
    ELEMENT ID (#PCDATA) ELEMENT CUSTOMER_RECORD (ACCOUNT_NAME, FIRST_NAME, LAST_NAME, TITLE)
    ELEMENT ACCOUNT_NAME (#PCDATA)
    ELEMENT FIRST_NAME (#PCDATA)
    ELEMENT LAST_NAME (#PCDATA)
    ELEMENT TITLE (#PCDATA)
    [2] Creation of XML map Data Definition type for Source and Destination are set to XML.
    While executing the procedure ‘XX_XML_DEMO_API . insert_customer_r’ in post_process from the message designer, instead of 2 (p_id IN number , p_customer IN customerRecordType) parameters it is showing 6 parameters (p_id IN number, p_customer IN customerRecordType, account_name IN varchar2, first_name IN varchar2, last_name IN varchar2, title IN varchar2). Six parameters are getting mapped, instead of the 2 that the procedure really needs.
    [3] Testing of XML map. Error message in transaction monitor:
    ORA-06550: line 1, column 7: PLS-00306: wrong number or types of arguments in call to 'INSERT_CUSTOMER_R' ORA-06550: line 1, column 7: PL/SQL: Statement ignored -
    ECX_ACTIONS.BIND_PROC_VARIABLES
    The process executed and produced the error message given in the step 3. The standard documentation is unclear on how this should be done. Being a newbie to the XML Gateway technology I am unable to get a clue about what the error message could be and which step of the process produced the message. Could anyone help me to proceed further?
    Thanks in advance.

    Hi Siva,
    It seems like the walletkey property of event type is defined incorrectly. Please try by defining the event as follows:
    <wlevs:property name="walletkey" type="char" length="20"/>
    Use "char" instead of "char[]".
    Best Regards,
    Sandeep

  • [BUG] jp2iexp.dll add-on for IE is registered with a wrong name/version

    jp2iexp.dll add-on for IE is registered with a wrong name/version. The name is Java Plug-in 1.6.0_07 but the version is +6.0.150.3+:
    Nome Java Plug-in *1.6.0_07*
    Autore Sun Microsystems, Inc.
    Tipo Controllo ActiveX
    Data file Oggi 5 agosto 2009, 27 minuti fa
    File jp2iexp.dll
    Versione *6.0.150.3*
    look this screenshot: http://img156.imageshack.us/img156/1707/jp2iexpdll.png

    Hello Amy.
    You may be having a problem with some Firefox add-on that is hindering your Firefox's normal behavior. Have you tried disabling all add-ons (just to check), to see if Firefox goes back to normal?
    Whenever you have a problem with Firefox, whatever it is, you should make sure it's not coming from one of your installed add-ons, be it an extension, a theme or a plugin. To do that easily and cleanly, run Firefox in [http://support.mozilla.com/en-US/kb/Safe+Mode safe mode] and select ''Disable all add-ons''. If the problem disappears, you know it's from an add-on. Disable them all in normal mode, and enable them one at a time until you find the source of the problem. See [http://support.mozilla.com/en-US/kb/Troubleshooting+extensions+and+themes this article] for information about troubleshooting extensions and theme. You can troubleshoot plugins the same way.
    If you want support for one of your add-ons, you'll need to contact its author.

  • I'm having a problem sending pictures from my Lucid phone, what's wrong

    I'm having a problem sending pictures from my Lucid phone, what's wrong?

    I'm trying to send a text message
       (aka Duchess)
    "I will lift up mine eyes unto the hills, from whence cometh my help. My help cometh from the LORD" PSALM 121:1-2a
    >Personal info removed<
    Message was edited by: Verizon Moderator

  • Hey guys getting upset about how i tunes is debiting $1 from my account every month is it happening yo anybody else..i didnt buy anything from the stores...whats wrong.. they just cant debit frm my acc???

    hey guys getting upset about how i tunes is debiting $1 from my account every month is it happening yo anybody else..i didnt buy anything from the stores...whats wrong.. they just cant debit frm my acc???

    Have the same problem here... don't know what to do...

  • [svn:bz-trunk] 8910: Bug: LCDS-936 - Should have better error message in servlet log if server in services-config .xml is configured to use wrong class.

    Revision: 8910
    Author:   [email protected]
    Date:     2009-07-29 14:22:26 -0700 (Wed, 29 Jul 2009)
    Log Message:
    Bug: LCDS-936 - Should have better error message in servlet log if server in services-config.xml is configured to use wrong class.
    QA: Yes
    Doc: No
    Checkintests: Pass
    Ticket Links:
        http://bugs.adobe.com/jira/browse/LCDS-936
    Modified Paths:
        blazeds/trunk/modules/core/src/flex/messaging/MessageBrokerServlet.java

    After many hard working days.i finally found the error cause,i needed to make weblogic datasource also ADF doesnt work on internet explorer browser,it works on safary.hope it helps somebody

  • I am not able to send my slideshow from iphoto because I entered the wrong username (e-mail address) by accident.  I cant see how to edit it. Can anyone help me?

    I am not able to send my slide show from iPhoto because I entered the wrong user name (e-mail address) by accident and I dont see how to edit it.  Can anyone help me out?

    Try here:
    iTunes Store: My credit card's security code or zip code does not match my bank's records
    Then try contacting iTunes
    Apple - Support - iTunes - Contact Us

  • I hear buzzz type sounding from my laptop. What is wrong with it?

    I hear buzzz type sounding from my laptop. What is wrong with it?

    I have the same problem with my 5th-generation iPod! In addition to the red-slashed circle, my iPod will not show up in iTunes nor will it charge until I forcefully eject it and reset it.
    Here is how I have learned to "fix" this problem over the years: make sure your iPod is fully charged before you try to plug it into your computer. The red-slashed circle comes on initially but you'll see that there's activity going on pretty quickly. The key seems to be having the iPod completely charged; even the slightest bit of depletion of battery makes everything go wrong.
    If this fails, make sure iTunes is already open before you plug in your fully charged iPod. Finally, if this fails as well, disconnect your internet connection, have iTunes open, and then plug in your fully charged iPod. These last ideas are probably more placebo than truly useful, but I have had luck with them when I'm ready to throw my iPod and laptop out the window.
    Hope this helps.

  • I cannot restore my iphone4 from back up as it says wrong password even if it is right password. what should i do?

    i cannot restore my iphone4 from back up as it says wrong password even if it is right password. what should i do?

    If it says wrong password, evidently what you're typing isn't it. Remember it is CaSe SenSiTiVe, a zero is not an Oh, a one is not the letter l and spaces count.
    And make sure you're typing in the same language keyboard it was originally typed in.

Maybe you are looking for