Skip to content

SelectedTax

The SelectedTax property is used to select the tax to be used in subsequent calculations. For example,

// using TaxControls;
try {
TaxControl tc = new TaxControl();
tc.DataFilename = "us.dat";
tc.SelectedTax = "federal income tax";
} catch (TaxControlException e) {
Console.WriteLine(e.Message);
}
//import com.boondocks.taxcontrols.*;
try {
TaxControl tc = new TaxControl();
tc.setDataFilename("us.dat");
tc.setSelectedTax("federal income tax";
} catch (TaxControlException e) {
e.printStackTrace();
}

Setting the value to a nonexistent tax will cause a run-time error.

Syntax

value = object.

object. value

Part Description
object A TaxControl object.
value A string result/expression.