BAPI to create an incoming Payment

Hi,
I have to create an incoming payment (FB01). The posting keys will be 40 and 15.
Wich BAPI could do this ?
(We don't have BAPI_ACC_DOCUMENT_POST).
Thanks.
Sandrine

Which version do you have ?
Look for FM/BAPI begining with BAPI_ACC (OSS [Note 306504 - Collective note: BAPIs for the AC interface|https://service.sap.com/sap/support/notes/306504]), or look for oldest function module like POSTING_INTERFACE_START, [POSTING_INTERFACE_DOCUMENT|https://www.sdn.sap.com/irj/sdn/advancedsearch?query=posting_interface_document&cat=sdn_all] and POSTING_INTERFACE_END.
Regards

Similar Messages

  • BAPI to process mutiple incoming payments

    Hi Experts,
    Is there any BAPI to post mutiple incoming payemnts. As of now i get file from the bank for the customer payments debited from there card , I am using BAPI 'BAPI_ACC_DOCUMENT_POST' to process the data sent to us from the bank. With this BAPI i can only post 1 invoice at time and as the data is large this program is taking a lot of time and some times gets timeouted. The user wants to run in foreground. So if you can provide any BAPI to post mutiple incoming payments at once it would be of great help.
    Thanks in Advance
    Mahesh

    Hi,
    Logically it doesn't make much difference in execution time whether you call document by document or once for all documents as the number of documents to be posted still remains. One option is, you can split your file into smaller chunks. Why can't this be processed in background (As batch job)?
    If user want to see the log, it would be available in spool and the same can be sent as mail.
    Thanks,
    Vinod.

  • Create draft incoming payments

    Hi all,
    i am having great difficulty in creating draft incoming payments through the DI, whatever I seem to do I cannot see the sort of properties that the help files say are there e.g. .cashsum .transferaccount etc. The only propoerties that are shown are the ones for marketing documents. I have tried all combinations of the two sets of code below but nothing seems to work,
      Dim DraftPay As SAPbobsCOM.Documents = GetDIConnection.GetBusinessObject(SAPbobsCOM.BoObjectTypes.oIncomingPayments)
      DraftPay.DocObjectCode = SAPbobsCOM.BoObjectTypes.oIncomingPayments
    Dim DraftPay As SAPbobsCOM.Documents = GetDIConnection.GetBusinessObject(SAPbobsCOM.BoObjectTypes.oPaymentsDrafts)
      DraftPay.DocObjectCode = SAPbobsCOM.BoObjectTypes.oPaymentsDrafts
    In trying to fix this issue i have given up on the idea of creating a draft and tried to create a simple incoming payment but i hit the same issue. Whatever I seem to do I only get the option to use marketing document properties.
    Am I missing something obvious or has someone else hit this issue (I am using V2007 by the way)
    Any help would be appreciated as we begin training on this system in two weeks!
    Gordon

    Hi,
    you create payments like
    vb6 samples:
    Dim oPay As SAPbobsCOM.Payments
    Set oPay = vCompany.GetBusinessObject(oIncomingPayments)
    Set oPay = vCompany.GetBusinessObject(oVendorPayments)
    Set oPay = vCompany.GetBusinessObject(oPaymentsDrafts)
    for drafts you also have to set:
    oPay.DocObjectCode = bopot_IncomingPayments
    or
    oPay.DocObjectCode = bopot_OutgoingPayments 
    i hope it helps
    lg David

  • Include the Journal entry created in Incoming Payments PLD

    Hello Experts!!!
    Is there a way to include the journal entry created in the Incoming Payments PLD?

    hi jennifer,
    You can create query print layout designer report using query.
    SELECT
    T0.TransId, T0.BaseRef, T0.RefDate,
    T1.Account, T1.ShortName, T2.AcctName,
    T1.Debit, T1.Credit
    FROM OJDT T0  INNER JOIN JDT1 T1 ON T0.TransId = T1.TransId and
    T1.TransType = 24 INNER JOIN OACT T2 ON T1.Account = T2.AcctCode
    WHERE
    T0.BaseRef = '[%0]' or  T0.RefDate = '[%1]'
    Jeyakanthan

  • Create A/R Invoice and Its Incoming Payment using DI Server

    Hi Everyone,
    I need to create an A/R Invoice and its payment in a sigle transaction using DI Server. The problem is that I don't know the DocEntry that will be assigned to the invoice in order to set it in the SOP message for creating the incoming payment.
    I guess the SOAP message should look like:
    <?xml version="1.0" encoding="UTF-16"?>
    <env:Envelope xmlns:env="http://schemas.xmlsoap.org/soap/envelope/">
    <env:Header>
      <SessionID>F46EDCE6-3F79-1F9F-1D1E-DC6226D04FA7</SessionID>
    </env:Header>
    <env:Body>
    <dis:AddObject xmlns:dis="http://www.sap.com/SBO/DIS" CommandID="Add invoice">
      <BOM>
       <BO>
        <AdmInfo>
         <Object>oInvoices</Object>
        </AdmInfo>
        <Documents>
         <row>
          <DocDate>20040707</DocDate>
          <DocDueDate>20040707</DocDueDate>
          <CardCode>BP</CardCode>
         </row>
        </Documents>
        <Document_Lines>
         <row>
          <ItemCode>Item1</ItemCode>
          <Quantity>3</Quantity>
          <TaxCode>My Tax</TaxCode>
         </row>
        </Document_Lines>
      </BO>
      </BOM>
      </dis:AddObject>
      <dis:AddObject xmlns:dis="http://www.sap.com/SBO/DIS" CommandID="Add Incoming Payment">
      <BOM>
       <BO>
        <AdmInfo>
           <Object>oIncomingPayments</Object>
        </AdmInfo>
        <Payments>
           <row>
               <CardCode>BP</CardCode>
               <DocTypte>rCustomer</DocTypte>
           </row>
       <Payments>
       <Payments_Invoices>
            <row>
                 <DocEntry>???</DocEntry> <---- ???
                 <InvoiceType>it_Invoice</InvoiceType>
                <SumApplied>100</SumApplied>
            </row>
       </Payments_Invoices>
       </BO>
      </BOM>
    </dis:AddObject>
    </env:Body>
    </env:Envelope>
    Any help?

    Dear Hugo Moreno,
    You could use the GetNewObjectCode Method of the Company Object to retrieves the key of the last added record.
    Please refer to SDK DI API help for this method.
    Best Regards
    Jane Jing
    SAP Business One Forums team

  • Error creating incoming payment. (ODBC -2035)

    The error that I get while creating an incoming payment is:
    This entry already exists in the following tables (ODBC -2035)
    Here is the code:
    public static bool CreatePayment()
           DateTime now = DateTime.Now;
           Payments pmt = (Payments) m_company.GetBusinessObject(BoObjectTypes.oIncomingPayments);
                pmt.ApplyVAT = BoYesNoEnum.tYES;
                pmt.CardCode = invoice.CardCode;
                pmt.CardName = invoice.CardName;
                pmt.CashSum = 0;
                pmt.ContactPersonCode = invoice.ContactPersonCode;
                pmt.DocCurrency = invoice.DocCurrency;
                pmt.DocDate = now;
                pmt.TaxDate = now;
                pmt.DocRate = 0;
                pmt.LocalCurrency = BoYesNoEnum.tYES;
                pmt.DocType = BoRcptTypes.rCustomer;
                pmt.HandWritten = BoYesNoEnum.tNO;
                pmt.JournalRemarks = "journal remarks";
                pmt.Remarks = "remarks";
                pmt.Reference1 = baseEntry.ToString();
                pmt.TransferSum = 0;
                // invoice
                pmt.Invoices.AppliedFC = 0;
                pmt.Invoices.DocEntry = baseEntry;
                pmt.Invoices.DocLine = 0;
                pmt.Invoices.InvoiceType = BoRcptInvTypes.it_Invoice;
                pmt.Invoices.SumApplied = amount;
                // credit card
                pmt.CreditCards.AdditionalPaymentSum = 0;
                pmt.CreditCards.CardValidUntil = Util.CCDateToDateTime(cardExpirationDate);        
                pmt.CreditCards.CreditCard = bp.CreditCardCode;
               pmt.CreditCards.CreditCardNumber = ccNumber;
                pmt.CreditCards.CreditSum = amount;
                pmt.CreditCards.CreditType = BoRcptCredTypes.cr_InternetTransaction;
                pmt.CreditCards.FirstPaymentDue = now;
                pmt.CreditCards.FirstPaymentSum = amount;
                pmt.CreditCards.NumOfCreditPayments = 1;
                pmt.CreditCards.NumOfPayments = 1;
                // there's a record in OCRP  (credit card payment methods)   
                pmt.CreditCards.PaymentMethodCode = 1;
                if (pmt.Add() != 0)
                    int errCode;
                    string errMsg;
                    m_company.GetLastError(out errCode, out errMsg);
                    // here errMsg is "This entry already exists in the following tables (ODBC -2035)"
                    return false;
                return true;
    I had 53 records in ORCT (incoming payments) but the next number in NNM1 and ONNM was 1. So I assumed that it was wrong and tried to set NNM1.NextNumber and ONNM.AutoKey to 54 for ObjectCode = 24 (Incoming payment).
    The error remained the same. Then I removed all records from ORCT and its subordinate tables RCT1, RCT2, RCT3,.... and changed the next number back to 1.
    The error is still: "This entry already exists in the following tables (ODBC -2035)".
    Do you have any ideas what may cause the above error and how I can get more info which is the entry that already exists and in which table?
    The code above works on another company (database).
    Thanks.
    Svilen

    Thanks Alexey,
    Please note that I have manually modified SBO tables once the problem appeared not before. I do not know how receipt numbers got out of sync.
    I also find the message "This entry already exist in the following
    tables" without actually specifying any table, strange, the least.
    The SDK is not particularly good and the samples in the help file are outdated and therefore wrong.

  • Create incoming payments, based on Sales Person code

    Hi all,
    is there any SAPB1 functionality to create incoming payments, for many Sales Invoices of different customers , based on a Sales Person code ?
    Thank you,
    Aris Pantelatos

    Hi Jitin and Gordon,
    Thank you both for your replies.
    Jitin, I need to create different incoming payments (one for every customer)  based on a list of invoices with a specified Sales Person on them.
    Do you know, if this is included on SAPB1 roadmap?
    Aris
    Edited by: Aris Pantelatos on Feb 8, 2012 4:04 PM

  • Create Incoming payment from an A/R Invoice

    Hello,
    I am on SBO2005A SP01 PL39 and do not find the option to create Incoming payment from an existing Invoice. When I open an existing A/R Invoice and click on CopyTo it shows only A/R Credit Memo. I remember seeing the Incoming Payment option in the earlier patch. Does this mean I cannot create an Incoming Payment based on an A/R Invoice?
    Thanks and Regards,
    Sheetal

    Sheetal,
    Just to clarify, the Incoming Payment has never been available as a Copy to option from Invoice.
    The Incoming Payment resides inside the Banking module. 
    From Main Menu > Banking > Incoming Payment ...Incoming Payment
    The only time the Payment Means window will automatically open when you Add the Invoice is when the Payment Terms of the Business Partner is setup to open Payment Means window.
    Suda

  • No matching record found when creating Incoming Payment...

    Hi,
    I'm starting a transaction, creating a invoice and then creating a incoming payment.
    The invoice is created successfuly in memory I can see the next DocEntry and DocNum and passing it to the incoming payment as usual but I'm getting the error : No matching records found
    Any idea ?

    I found why.
    The Series used was not there.  But it's not obvious to know that it's because you set a wrong Series code with an error like this.

  • Error on creating Incoming Payment that links to another Incoming Payment

    Hi Experts,
    I am trying to create an Incoming Payment to pay an Invoice, as well as to use another Incoming Payment with an open balance (with Payment On Account box checked) to offset part of this payment.
    Conceptually...
    Incoming Payment A (-$75)
       --- link to Invoice B   ($85)
       --- link to Incoming Payment C  (-$10)
    This can be done manually, but by using DI API, I am facing this error:
    "-10: Base document card and target document card do not match.  (RCT2.DocLine)(line: 2)"
    Here is the source code:
    Dim oPayments As Payments = DirectCast(oCompany.GetBusinessObject(BoObjectTypes.oIncomingPayments), Payments)
    ' [HEADER]
    oPayments.CardCode = "C0001"
    oPayments.DocDate = Today
    oPayments.DocType = BoRcptTypes.rCustomer
    oPayments.CashSum = 0
    oPayments.BankChargeAmount = 0
    oPayments.TransferAccount = "12180208"
    oPayments.TransferDate = Today
    oPayments.TransferSum = 75
    oPayments.LocalCurrency = BoYesNoEnum.tYES
    ' [LINE 1 - AR Invoice B.]
    oPayments.Invoices.InvoiceType = BoRcptInvTypes.it_Invoice
    oPayments.Invoices.DocEntry = 16949
    oPayments.Invoices.SumApplied = 85
    ' [LINE 2 - Incoming Payment C with Open Balance.]
    oPayments.Invoices.Add()
    oPayments.Invoices.InvoiceType = BoRcptInvTypes.it_Receipt
    oPayments.Invoices.DocEntry = 20338           ' Journal Entry Number of the Incoming Payment
    oPayments.Invoices.SumApplied = -10
    If oPayments.Add() <> 0 Then
        oCompany.GetLastError(errCode, errMessage)
        BarError(String.Format("{0}: {1}", errCode, errMessage))
    Else
        BarSuccess("Success.")
    End If
    Initially I tried to set
    oPayments.Invoices.DocEntry
    with the Incoming Payment's DocEntry, but after trial and error, I realized I should be using the Incoming Payment's Journal Entry's Number instead. So this field should be correct. (If I were to use the Incoming Payment's DocEntry for this field, I get the "-2028: No matching records found (ODBC -2028)" error.)
    I have ensured that the Incoming Payment C's CardCode is the same as the one I set in
    oPayments.CardCode
    , so I'm not sure why it gives an error saying the document cards do not match. I would appreciate any form of help on this! Thanks!

    Hi,
    I am not trying to Pay to Account (you are referring to the top left radio button of the Incoming Payment right?). I am trying to create an Incoming Payment that uses another over-paid Incoming Payment (i.e. Open Balance > 0) to offset its Amount Due.
    Anyway I have found the solution to my problem. It seems that I need to also set the
    oPayments.Invoices.DocLine
    value to the over-paid Incoming Payment's Journal Entry's document line which contains the same business partner as my Incoming Payments. This DocLine value is usually 1 (0-based), as SAP usually creates the Journal Entry with the BP row in the second row.

  • Post an incoming payment ( check ) against an invoice

    Hi
    I am trying to post an incoming payment ( cheque ) against an invoice. I keep getting no matching records found ( odbc error -2028 )
    Has anyone got a simple example I could use as a comparison please ?
    Thanks
    Regards Andy

    I had a similar problem.  Just make sure you have the proper Invoice number and that everything exist in SAP
    This error means that to create your incoming payment, the SDK needs everything created prior to make an incoming payment.   Exactly as if you would do it in SAP
    So just make sure everything is there and that you refer to the right Invoice
    Good luck

  • Incoming payments - payment on account

    Hi,
    I am trying to create an incoming payment(payment on Account) using SDK . Which property i should use to make a Payment on Account?
    Thanks,
    Jayakumar

    Hi Jayakumar,
    That'll be something like
    vPay = vCompany.GetBusinessObject(oIncomingPayments)
    vPay.DocType = SAPbobsCOM.BoRcptTypes.rAccount
    Try filling the same properties you do when you create a payment with the GUI.
    Hope this helps,
    Ian

  • Error incomming payment cash

    Hi
    I have a problem when create a incoming payment from customer
    creating  journal entry, payment, and add the journal entry on the payment
    if the invoice is partially paid the payment is created sucessfully
    but if the invoice is not paid send a error
    error code:-10
    description:Enter valid code  [JDT1.ContraAct][line: 1] , 'SN0001'  [??????? 173-36]
    here ir the code:
                        //creating journal entry
                        var entry = company.GetBusinessObject(BoObjectTypes.oJournalEntries) as JournalEntries;
                        var cuenta = parametros.CodigoCuentaContableAnticiposClienteExportacion;
                        entry.TaxDate = pago.FechaCreacion;
                        entry.ReferenceDate = pago.FechaCreacion;
                        entry.DueDate = pago.FechaCreacion;
                        entry.Reference = "Aplic Anticipo cliente";
                        entry.Memo = "Aplic ANTICIPO CLIENTE";
                        entry.Reference2 = pago.Codigo.ToString();
                        entry.Lines.ShortName = pago.ClientePago.CardCode;
                        entry.Lines.Credit = (double)pago.Anticipado;
                        entry.Lines.TaxDate = entry.TaxDate;
                        entry.Lines.Add();
                        entry.Lines.SetCurrentLine(1);
                        entry.Lines.ShortName = cuenta;
                        entry.Lines.Debit = (double)pago.Anticipado;
                        entry.Lines.TaxDate = entry.TaxDate;
                        var statusPoliza = entry.Add();
                        if (statusPoliza != 0)
                            return;
                        var polizaAnticipo = company.GetNewObjectKey();
                        //creating payment
                        var payment = company.GetBusinessObject(BoObjectTypes.oIncomingPayments) as Payments;
                        payment.CardCode = client;
                        payment.DocDate = pago.FechaCreacion;
                        payment.DocType = BoRcptTypes.rCustomer;
                        payment.DocCurrency = "MXP"
                        var remarks = pago.PagoFacturas.Aggregate<PagoFactura, string>("",(folios, factura) => folios += "," + FolioImpreso).Substring(1);
                        if (remarks.Length > 50)
                            remarks = remarks.Substring(0, 47) + "...";
                        payment.JournalRemarks = remarks;
                        payment.Remarks = pago.Observaciones.Substring(0, pago.Observaciones.Length >= 254 ? 253 : pago.Observaciones.Length);
                        var pagar = pago.MontoPago
                        payment.CashAccount = pago.TipoMercado == TipoMercado.Exportacion ? "_SYS00000000123" : CodigoCuentaContableRedondeo;
                        payment.CashSum = (double)0.01;                   
                        var line = 0;
                        foreach (var pagoFactura in pago.PagoFacturas)
                            var factura = pagoFactura.FacturaCliente;
                            var folio = "";
                            var monto = 0m;
                            folio = factura.FolioSAP;
                            monto = pagoFactura.Monto
                             if (line != 0)
                                payment.Invoices.Add();
                            payment.Invoices.DocEntry = int.Parse(folio);
                            payment.Invoices.InvoiceType = BoRcptInvTypes.it_Invoice; //BoRcptInvTypes.it_JournalEntry Así se indica que es una poliza
                            payment.Invoices.SumApplied = (double)monto;
                            line++;
                             // add the journal entry on the payment
                            if (line != 0)
                                payment.Invoices.Add();
                            payment.Invoices.DocEntry = int.Parse(polizaAnticipo);
                            payment.Invoices.InvoiceType = BoRcptInvTypes.it_JournalEntry; //Así se indica que es una poliza
                            payment.Invoices.SumApplied = -(double)pago.Anticipado;
                            line++;
                        var status = payment.Add();
    I hope that you can help me
    i'm usgin .net and DI API 9.0

    Gracias por la respuesta alejandro
    realmente no es SN0001, lo puse solo de ejemplo
    pero el error lo marca en la linea
    var status = payment.Add();
    y si el error me dice que es algo del asiento contable, pero que se me hace raro es que si la factura ya tiene algo pagado, si registra bien el pago.
    y tambien si intento hacer ese mismo pago en sap directamente me marca una advertencia pero si me deja continuar
    me dice esto.
    a cash account is required, chossing a diferent account may cause inaccurancies in the cash flow report

  • Incomming Payment with a Postdated Check

    I need to create several Incoming Payments for several Invoices with postdated checks. The problem is that most times, the general manager does want those Invoices to be still shown in the Aging Report. I tried several things, including saving the incoming payment as a Draft but when it changes Posting Period, it causes problems.

    Are you post dating the checks, or the incoming payment? Perhaps if you post date the incoming payment document, the invoices may still appear on the aging report? I have not tested this, but it would seem to be logical

  • Cancel Incoming Payment (if Pay by credit card)

    Hi..
    I want to ask,
    how to Cancel Incoming Payment (if pay by credit card), and incoming payment created one month ago..
    If i create new incoming payment, and i cancel, it works..
    But if i find old incoming payment, i cant cancel it
    the error sounds: "one of the credits voucher was cashed".
    any idea to solve this problem?
    Thankyou for your help
    regards

    Hi Dony,
    Issue is described in SAP Note 542274. I assume that mentioned credit voucher is overdue, and the settings in Administrations - System Initialization - General Settings - Sales tab, Submit Credit Vouchers is  "Automatically". It means, that credit voucher is already deposited, you can check it in Banking - Deposits - Deposit - Cheques/Credit Card/Cash tab(It depends on the payment means of incoming payment).         
    It is not possible to cancel deposited credit vouchers, you must to     
    create a similar Incoming Payment with negative amounts and deposit it. 
    Regards,
    Paul

Maybe you are looking for

  • I don't understand why my loop isn't working. Can someone help, please?

    public class PolarMain {      public static void main(String[] args) {           Polar p1 = new Polar(45, 50, 10, 10);           System.out.println(" X1 " +p1.x1 +" New X1 " + p1.newX(45, 50 , 10 , 10)            + " Y1 " +p1.y1 +" New Y1 " + p1.newY

  • Can't convert PDF from desktop

    The convert panel appears when I open a PDF doc, but from that panel will not upload PDF to Adobe for conversion.  I have to go online to Adobe to do it.  What's wrong?  It used to work.

  • DC Build Error with Web Dynpro Project

    Hi, I have created a DC Project and migrated all the local Web Dynpro project to the DC project which is connected to NWDI. When I performed a Development Component Build, I am getting tons of errors like this : C:\Documents and Settings\mlee20\.dtc\

  • Downpayment..milestone..periodic billing...WBS element...

    downpayment..milestone billing.....periodic billing...WBS element...billing plan..commission agent....rentals...extra work in construction...cancellation of flat..allotment of parking..sale of real estate unit..sale of TDR..sale of services...payment

  • Which Mac to Buy for Use with Logic?

    I'm currently looking to buy a new Mac and am torn between the iMac and Macbook Pro. iMac is definitely in my price range more than the Macbook. I'm looking to do basic video editing and audio recording (15 tracks at most) most likely using an Apogee