To modify a tax, you must perform the following:
- Get an instance of the orders manager.
Get an instance of the OrdersManager object.
- Get the specified tax.
Get an instance of the tax. For more information, read Querying taxes.
- Modify the instance of the tax.
Update the values of the properties of the tax. For more information about modifying the tax class rates, see Setting the tax class rates.
- Save the changes.
Save the changes to the manager.
Here is a code example:
ModifyTax(Guid taxId, AddressType type)
OrdersManager ordersManager = OrdersManager.GetManager();
Tax tax = ordersManager.GetTax(taxId);
tax.AddressType = type;