Skip to Content

Archived discussions are read-only. Learn more about SAP Q&A

Looking for tax on item

Hello,

I want to know how much tax is charged on an item. I know that the Id is in SalesVATGroup and I want to find the Tax in OVTG. But OVTG is no part of the DI-API. What should I do?

rgds,

John

replied

Maybe this will do the trick? Replace "myCodeValue" with the actual code:

---

Dim oRecordSet As SAPbobsCOM.Recordset
Dim taxRate As Double
 
'// Getting an initialized Recordset object
oRecordSet = oCompany.GetBusinessObject(SAPbobsCOM.BoObjectTypes.BoRecordset)
		
'// Performing the select statement
'// The query result will be loaded
'// into the Recordset object
oRecordSet.DoQuery("SELECT Rate FROM OVTG WHERE Code = 'myCodeValue'")

taxRate = oRecordSet.Fields.Item(0).Value

0 View this answer in context
Not what you were looking for? View more on this topic or Ask a question