cancel
Showing results for 
Search instead for 
Did you mean: 

BAPI for MIRO

Former Member
0 Kudos

hi

i need to do Invoice Receipt against the POs.We do this manually with MIRO with reference to PO.how can i find this bapi.Please let me know which BAPI suitable for this.

thanks,

siva.

Accepted Solutions (1)

Accepted Solutions (1)

GauthamV
Active Contributor
0 Kudos

Use these bapi.

BAPI_INCOMINGINVOICE_CREATE

BAPI_INCOMINGINVOICE_PARK.

Answers (2)

Answers (2)

Former Member
0 Kudos

thanks

Former Member
0 Kudos

Hi Ramraju,

BAPI_INCOMINGINVOICE_CREATE , requires GRN document number for posting invoice. However, if we are doing MIRO before GRN , then we will not have this document number.

In that case , what other BAPI can I use to post invoice.

Plesae help.

Tahnks & Regards

Jajati

Former Member
0 Kudos

BAPI_INCOMINGINVOICE_CREATE

Regards

Vinod

Former Member
0 Kudos

hi,

When i run this BAPI which asking RFC. This is not matches for me. I need normal BAPI not through IDOC.

thanks,

siva.

Former Member
0 Kudos

RFC is not required. Check the sample code

loop at it_ekpo .

    itemdata-invoice_doc_item =  sy-tabix .
    it_material-invoice_doc_item = sy-tabix.
    it_material-material = it_ekpo-matnr.
    it_material-val_area = it_ekpo-werks.
    it_material-db_cr_ind = 'X'.
    it_material-tax_code = it_ekpo-mwskz.
    it_material-quantity = it_ekpo-menge.
    it_material-base_uom_iso = it_ekpo-meins.
    itemdata-po_number  = it_ekpo-ebeln .
    itemdata-po_item = it_ekpo-ebelp .
    itemdata-item_amount = it_ekpo-netpr * it_ekpo-menge .
    itemdata-quantity = it_ekpo-menge .
    itemdata-po_unit  =  it_ekpo-meins .
    append itemdata to itemdatat .
    append it_material.
  endloop .

  headerdata-invoice_ind =  'X' .
  headerdata-doc_date    = sy-datum .
  headerdata-pstng_date  = sy-datum .
  headerdata-ref_doc_no  = 'Test-Inv' .
  headerdata-comp_code   = '0101' .
  headerdata-currency    =  'INR'..
  headerdata-gross_amount = '990.00'.

it_tax-tax_code = 'V0'.
it_tax-tax_amount = '90'.
it_tax-tax_base_amount = '990.00'.
append it_tax.


call function 'BAPI_INCOMINGINVOICE_CREATE'
    exporting
      headerdata                = headerdata
   importing
     invoicedocnumber          =    invoicedocnumber
     fiscalyear                =    fiscalyear
    tables
      itemdata                  = itemdatat
      materialdata              = it_material
      taxdata                   = it_tax
      return                    = return .
  call function 'BAPI_TRANSACTION_COMMIT'.

Regards

Vinod

Former Member
0 Kudos

Hi experts ,

i have a one invoice script there now i want add customer name it will be displayed for only some plants , so that i add text element in script lay out and put condition also. but it is not triggered properly ,

can any one help how to debug particular point.

Thanks,

Siva

Former Member
0 Kudos

hi,

Once the GR is posted successfully for all the POs, I need to do Invoice Receipt against the POs. We do this manually with MIRO with reference to PO.I need to use BAPI for this. Please let me know which BAPI i can use here.

thanks,

siva.