Edit

GetTaxRate (taxCode, date [,bReversed])

Result Type:  Number

Definition:  Given a tax code and a date, returns the tax rate for that code on that date.

From v9.1.1, A "reversed" tax type will return zero from this function (since reversed rates are not calculated on transactions). You can obtain the actual reversed rate for reporting purposes by passing TRUE for the third parameter.

Examples:  GetTaxRate("G", today())

Returns the rate for the "G" taxcode as at today, for example 0.15 (15%).

GetTaxRate("G", '1/1/10')

Returns the rate for the "G" taxcode as at 1st January 2010, for example 0.125 (12.5%).

Note:  Because the rate is determined by the ChangeOver Date for the tax in the Tax Rate table, the function is not able to determine the correct rate for tax changes prior to the date of a tax change (if any) before the last tax rate change.