Invoice from Delivery

How can I know if an invoice is generated from a delivery or from an order ?
What is the delivery ref. number inside the OINV table ?
Thank you !
Giuseppe

Hi Giuseppe,
The reference is at the row level.
You must check the INV1.BaseType field.
If INV1.BaseType = -1 it's not based on another document;
If INV1.BaseType = 15 it's based on a Delivery;
If INV1.BAseType = 17 it's based on a Sales Order.
Regards,
Vítor Vieira

Similar Messages

  • How create an invoice from delivery using an idoc

    Hi expert,
    I'll like recive an help to know how implement the following solution: we would create an invoice from delivery sent into the idoc structure.
    In detail the process that we would implement is:
    To use an output type for outbound delivery and to assign a program to it in order to create an idoc when the output type is processed; when the idoc is created the program has to call the transaction VF01 to create the invoice from the idoc.
    Which type of idoc do we have to use?
    How the VF01 call transaction should be excuted?
    Many thanks in advance
    Regards
    Roberta

    Check with following standard basic IDoc types:
    INVOIC01- Invoice/Billing document
    INVOIC02 - Invoice/Billing document
    INV_ID01 - Invoice
    SISINV01- SIS - billing document
    And refer following link for understanding: [iDoc|http://wiki.sdn.sap.com/wiki/pages/viewpage.action?spaceKey=HOME&title=StepbyStepprocedureforcreationof+IDOC&decorator=printable]
    I hope this can assist you.
    Thanks & Regards
    JP

  • Customer Down Payment invoice (from delivery) not automatically assigned

    If I create a Down payment invoice from Sales Order (and I paied it) on the final invoice the sistem automatically assigne the down payment invoice on the final invoice for the order.
    If I do the same think but crerating the Down payment invoice from the delivery (and I paid it) when I create the final invoice I need to assigned it manually.
    SBO 8.81 PL 06
    I haven't found any set up for this, so I think is an error the sistem must work on the same way if the document is copied from the Sales order or delivey.
    Someone know if there is some set up? or I need to open an error message to SAP?
    Thanks

    My question is:
    If I make a sales order.
    I create a down payment invoice using copy from SO.
    I make the incomuing payment for the down payment invoice.
    I create the delivery from the SO
    I create the invoice from the delivery
    The system apply automaticaly the down payment invoice to the invoice (because I select a delivery that is linked to the so that I used to create the down payment invoice).
    If I make a sales order.
    I create the delivery from the SO
    I create a down payment invoice using copy from delivey.
    I make the incomuing payment for the down payment invoice.
    I create the invoice from the delivery
    The system DO NOT apply automaticaly the down payment invoice to the invoice (even if also this document is linked to the delivery that I use to create the down payment invoice).
    I know that I can select it manually. But I can select it manually also if I use the SO to create the down payment instead of the
    delivery. Why if the situation is the same in the firs case the system do it automatil^cally and in the second case I need to do it manually?
    Of course if I create a Down Payment invoice without selecting any document (SO, delivery..) the system don't know if you want to apply the payment to the final invoice.
    But If I select the delivey to create the down payment (the same if I select the SO): I want to apply the down payment to the final invoice of this delivery and not to another delivery.

  • Cannot create A/R Invoice from Delivery

    Hi everyone.
    I have a Delivery based on a Sales Order and want to make an A/R Invoice from the Delivery using the "Copy to" button on the Delivery form. When I do that I get the following message:
    "One or more down payment that are linked to the base document(s) have not been paid. Continue?"
    When I press "Yes" the following error occurs:
    "Business partner of copied down payment document must be the same as business partner of target document."
    But I didn't create any down payments.
    Do you have any suggestions as to what may be the cause of the problem?
    Vladimir.

    Hi Vladimir,
    What is your B1 version and PL? Is there any relation between your question and SDK?
    Thanks,
    Gordon

  • Copying Invoice from Delivery notes

    Hi,
    I want to create an Invoice document from a Delivery document. Is there a straight-forward way in DI-API to do that?
    Please post any code segment you have.
    I'll appreciate your help.
    Thanks.
    -Geetha

    Hi Geetha,
    no there isnt
    you have to copy all properties with your own code
    oInvoice.CardCode = oDeliverNote.CardCode
    and "connect" the Lines
    oInvoice.Lines.BaseLine = oDeliverNote.Lines.LineNum
    oInvoice.Line.BaseEntry = oDeliverNote.DocEntry
    oInvoice.Line.BaseType = 15
    regards
    David

  • How to stop creating mutiple performa invoice from delivery document

    case -
    i am creating stock transfer performa invoice on the basis of stock trf purchase order and delivery document. i want to stop creating multiple performa invoice.
    Mukesh Kumar

    If your requirement is to generate a certain output automatically only once for a certain document, you can set it for the output type in  transaction NACE (for example - NACE --> select the application --> "Output types").
    There's a "Multiple issuing" indicator (VN_T685B-MEHRF) through which you can control the desired behaviour.
    Edited by: Csaba Szommer on Jul 28, 2010 1:40 PM
    Sorry, I misunderstood your question...please neglect the suggestions above...
    As per SAP online help there's no limitation how many proforma invoices can be created from one delivery / sales order:
    http://help.sap.com/erp2005_ehp_04/helpdata/EN/dd/5610c9545a11d1a7020000e829fd11/frameset.htm
    If you want to restrict this, I think you should follow KC's suggestion and modify your copy control routine.
    Since in standard system this function does not exists you won't find suitable copy routine. That's why - in my opinion - you should use the same copy routine which has been set till now - you just have to modify it (add an ABAP code to check whether proforma invoice is already created or not; maybe you can check the entries in table VBFA)
    Edited by: Csaba Szommer on Jul 28, 2010 1:46 PM

  • Cant copy A/R Invoice from Delivery

    Hello All
    Can anyone think of any reason why a customer of mine can not copy a delivery note to an A/R invoice - when they are trying to do this they are getting the error message - 'Account does not exist  [439-9]'
    Thanks
    Stuart

    Hello Stuart,
    You may check these threads first:
    G\L Account Determination
    how to change GL determination for Accounts Receivables account

  • Create invoice from delivery

    Hi,
    i have different  sales order numbers.against all these sales orders a delivery is created.now i want to create a invoice against this delivery.is there any bapi/fm to create invoice using this delivey only.(i dont have any po details i.e.no po is created)...can any one help me in finding this ...its an urgent thing.....thank you...
    Thanks,
    Bhaskar.

    You can use transaction VF01 in batch input mode (call transaction VF01 using ...)
    To get an idea of how batch input data should look like for this transaction use SHDB transaction before - to record an example VF01 transaction.
    Preparing batch input data for transaction VF01 is quite simple - all you have to do is to enter delivery document number and have diskette icon clicked.
    good luck

  • Output type for Proforma Invoice for return delivery from delivery type RLN

    Client require Output type Proforma Invoice for return delivery to vendor. As such return item category is not relevant for pricing so from delivery to proforma invoice can not have with p-ricing. I got quantity correct but pricing is coming Zero.
    Client have ZPAC as packing list output type from delivery which shows quantity and pricing. So decided to use the same logic to pull pricing for proforma invoice from delivery.
    Here delivery has standard output ZPAC as packing list with access sequence Z002 as Delivery Type.
    I want to pop up output type for all return delivery so using access sequence with delivery type/vendor.
    Vendor filed does not exist in delivery output type so brought that firld LIFNR.
    It is assigned to procedure and maintained ZPRO output type for Proforma invoice. Asigned VV21 on front end.
    Problem Still automatic output type ZPRO is not poping up. What type of access sequence will help me to pop up or what in configuration am I miising?
    Appreciate help for solution at earliest.

    Hi Padamsree,
    I know Pricing & output very well.  I need profomra invoice to be printed with quantity & value for return goods to the vendor. Pricing is associated with Item category RLLN for delivery type RLL which is return type delivery.
    I need to have pricing in my Proforma invoice which is copied from delivery to billing document VTFL. Just check well how it is working in the system & if you know please answer so that it should be workable on the system. As theoretical answer may not be helpful. Appreciate for your time.
    Thanks

  • IDOC for Invoice Issue from Delivery

    Hi All,
    We have requirement in which we need to trigger an IDoc after PGI is done to create an Invoice.
    I want to know the BASIC TYPE , Outbound Function Module and Inbound Function Module which should be used?
    Kindly help.
    Regards

    Hi shivram,
    Thanks for the reply.
    I want to create an invoice from delivery so i think i cant use this.

  • Create Excise invoice from Deilvery

    Dear All,
    I want to create Excise Invoice from delivery, is it possible?
    If yes, what are changes required to be done?
    with regards,
    Nikita Kale.

    Hi Lakshimipathy,
    What if we create excise invoice from J1IS.
    ( there will be a material document when we do PGI and based on the Assesable value and excise rate from J1ID, it has to work if its TAXINJ)
    My client does the same thing for STO , they even had a ouput programe for it.
    Any issue from the transaction type level, since in J1IIN , its DLFC and if its through J1IS its OTHR.
    Could you please advice on this.
    Thanks in Advance
    Asif Mohammed A

  • How to Generate an A/R Invoice from a DO automatically

    Dear all,
    Is there a way to generate an A/R Invoice automatically right after a user add an approved DO? Once hi clicks the <b>Add</b> button in Delivery screen, I want to show him the A/R Invoice screen completed with all items from the  base Delivery document.
    Thanks,
    Oki

    Well, i never try this but logically it does make sense
    First ,When You CLick Add Button in Form Delivery,you have to catch some variable from delivery data that will be used for Invoice.
    Second ,you add some DI programming with document object ( and off course its line item ) to add to new invoice with you variable from delivery 'but' dont forget to fill the <i>baseentry</i> <i>basetype</i> and <i>baseline</i> property ( in document_line object ) with delivery document info and in <i>closed property</i> in document object and invtstatus (using recordset i dont know that this property exist in document object), to make sure that the invoice is really base on Delivery.
    Dont Forget To Add The Journal Object For Invoice .
    After That You add some come to activate toolbar target
    SBOApplication.ActivateMenuItem "5899"
    That's All.Hopefully can help
    The Next Problem Occured is What IF we dont create invoice from delivery first ( not based on base document ) we create invoice directly for one time customer use ( we're not using Form One Time Customer ? )
    You have to consider this concern. Just An Suggesstion .
    Bty Are You From Be Logix Indonesia ? I heard your name some where
    Cheers,
    Hamdi / Metrodata

  • Single performa invoice from multiple delivery

    Dear sir,
    my client requirement is they are doing one delivery and creating one performa invoice in export scnario while selling from plant and while doing export issue they have to take refrence performaa invoive .
    so they want to create as ingle performa invoice from multiple delivery for which already respective performa invoices have been created.so i want a single performa invoice from multiple delivery so tell me how to do it?
    thanks
    Debesh

    Go to VTFL and maintain as follows:-
    At Header
    Copying requirements:::::::::009
    At Item
    Copying requirements:::::::010
    Data VBRK/VBRP::::::::::::003
    thanks
    G. Lakshmipathi

  • 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.

  • Creating Invoice from a Delivery Note using SDK

    Hi,
    I am working on SAP 2005 A Patch 4 with SQL 2000 SP 4. I am using VB.NET (VS2005). I am trying to create a Invoice from a Delivery note which is created based on a Sales order.
    I am getting the following error
    Error occured while saving Invoice: 0 - '15' is not a valid value for field 'BaseType'. The valid values are: '-1' - '',  '0' - '',  '23' - 'Sales Quotation',  '17' - 'Sales Order',  '16' - 'A/R Returns'
    The Code that i used to create the invoice is as follows
    Dim oInvoice As SAPbobsCOM.Documents
            oInvoice = pcompany.GetBusinessObject(SAPbobsCOM.BoObjectTypes.oInvoices)
            oDelivery = pcompany.GetBusinessObject(SAPbobsCOM.BoObjectTypes.oDeliveryNotes)
            Try
                If oDelivery.GetByKey(iDlvNo) = True Then
                    sTaxCodes = sTaxCode
                    oInvoice = pcompany.GetBusinessObject(SAPbobsCOM.BoObjectTypes.oOrders)
                    oInvoice.CardCode = oDelivery.CardCode
                    oInvoice.SalesPersonCode = oDelivery.SalesPersonCode
                    oInvoice.DocType = SAPbobsCOM.BoDocumentTypes.dDocument_Items
                    oInvoice.DocumentSubType = SAPbobsCOM.BoDocumentSubType.bod_None
                    oInvoice.Address = oDelivery.Address
                    oInvoice.ShipToCode = oDelivery.ShipToCode
                    oInvoice.Address2 = oDelivery.Address2
                    oInvoice.JournalMemo = "Invoice - " & oDelivery.CardCode
                    oInvoice.Comments = "Based on Delivery  " & oDelivery.DocNum
                    oInvoice.PaymentGroupCode = oDelivery.PaymentGroupCode
                    oInvoice.DocDueDate = Now.Month & "/" & Now.Day & "/" & Now.Year
                    For iRowNo = 0 To oDelivery.Lines.Count - 1
                        If iRowNo > 0 Then
                            oInvoice.Lines.Add()
                        End If
                        oDelivery.Lines.SetCurrentLine(iRowNo)
                        oInvoice.Lines.ItemCode = oDelivery.Lines.ItemCode
                        oInvoice.Lines.Quantity = oDelivery.Lines.Quantity
                        oInvoice.Lines.Rate = oDelivery.Lines.Rate
                        oInvoice.Lines.BaseType = SAPbobsCOM.BoAPARDocumentTypes.bodt_DeliveryNote
                        oInvoice.Lines.BaseEntry = iDlvNo 'DocEntry of Delivery Note
                        oInvoice.Lines.BaseLine = iRowNo
                        oInvoice.Lines.TaxCode = sTaxCodes
                    Next
                    iReturnValue = oInvoice.Add()
                    If iReturnValue <> 0 Then
                        pcompany.GetLastError(iReturnValue, sErrorDescription)
                        Throw New Exception("Error occured while saving Invoice: " + _
                                           iErrorNo.ToString() + " - " + sErrorDescription)
                    Else
                        MessageBox.Show("Invoice created succesfully")
                    End If
                End If
    Since in the error message it has specified that i have given the BaseType as Delivery which has a value of 15 i changed that from bodt_DeliveryNote to bodt_Order which has a value as 17.
    When i tried creating the invoice again it gave the error
    Error occured while saving Invoice: 0 - Target item number does not match base item number.  [RDR1.TargetType][line: 2]
    I am not able to proceed further ... can any one help me
    thanks in advance
    Ganesh

    Greetings,
    I am having a similar problem, only I'm doing it as suggested in Louis' reply.  In fact I copied that code and tried it.  It's giving me a 2028 error with no description.
    I had been doing it slightly differently and the error I was getting was 5002 "Item no. is missing [INV1.ItemCode][line 2]"  I don't have 2 lines and I'm certain I have an item code.  The numbers I'm putting in for baseentry & baseline are absolutely in the table and the order is open.
    Here is that code:
            oDNUpd = oCompany.GetBusinessObject(SAPbobsCOM.BoObjectTypes.oInvoices)
            oDNUpd.CardCode = CardCode.Text
            oDNUpd.Lines.BaseEntry = CInt(SalesOrder.Text)
            oDNUpd.Lines.BaseLine = CInt(baseline.Text)
            oDNUpd.Lines.BaseType = SAPbobsCOM.BoObjectTypes.oOrders
            oDNUpd.Lines.Add()
            lretcode = oDNUpd.Add
    I'm using SBO 2005 patch 7 (and the new dll).  I have similar code doing a stock transfer and it's working fine.
    Thanks for any suggestions you can offer
    John

Maybe you are looking for

  • How to Consolidate MULTIPLE iTunes Libraries?

    I've found myself in a situation where my iTunes file organization has gotten out of hand. Originally this occurred because I had an iBook with only a 60GB HD, storage was tight, so I had to keep my music on both an external HD as well as the iBook's

  • JCO Connection User

    Hi gurus, I'd like to ask you what kind of user you use for connection in JCO connections. For our test system I used my own user but in live system a stable user must be used? Any ideas? Tolga

  • InvocationTargetException when using the reflection package (Constructor)

    Hi there! its my first post in here and not an easy one I suppose. I have got a JFrame class that has a inner class to handle button events (the inner class implements java.awt.event.ActionListener). I have got a file browser to lookup a particular c

  • Losing permission to songs in my library

    In the past three weeks, I have been losing permission to songs in my library. I can locate the song in my ITunes library and the folder where they are stored, but the songs that I have lost permission to have "green ink". I have moved them out of IT

  • Photoshop Album Started changes .jpeg into .tiff

    I use Photoshop Album Starter 3.0 and have been very happy with it when using my Olympus Camera. I recently purchased a new Canon Powershot A470, and when downloading images from the camera, Photoshop Album changes a .jpeg into a .tiff. How do I tell