cancel
Showing results for 
Search instead for 
Did you mean: 

How to insert TAX information with the DI API

Former Member
0 Kudos

Hi All,

We have an ecommerce solution that calculate the accurate tax with a web service based on State, City and County. However we cannot insert into the TAX field through the DI API. I was considering different options like inserting the tax amount in a additional expense or sinchronizing the TAX code per state into the ecommerce so once a State is selected in the shipping address we know which tax percentage needs to be charge into the order? has anyone experienced something similiar?

Thanks in advance

Hector

Accepted Solutions (0)

Answers (1)

Answers (1)

Former Member
0 Kudos

Hi Hector,

If you need to set a tax code in a document row, use the following:


            Dim oDoc As SAPbobsCOM.Documents = oCompany.GetBusinessObject(BoObjectTypes.oInvoices)
            oDoc.CardCode = "C00001"
            oDoc.DocDate = Now
            oDoc.DocDate = Now
            Dim oDocRows As SAPbobsCOM.Document_Lines = oDoc.Lines
            oDocRows.ItemCode = "A00001"
            oDocRows.Quantity = 10
            oDocRows.VatGroup = "L13"
            ...

Some additional info (from the SDK Help File)

TaxCode Property

Sets or returns the sales tax code for the item specified in the row.

Country-specific property for USA

VatGroup Property

Sets or returns the VAT group for the item specified in the row.

Country-specific property for EU

This are the properties available for A-Cluster countries. If you're in a B-Cluster country you may have a different property available.

Regards,

Vítor Vieira