M
Marc H
I need to calculate a dollar amount for differently in each line of a table.
I have a [CalcMethod] field and currently use a SELECT CASE structure to do
the calculation depending on the value in [CalcMethod] and place the value in
[Total]. ex. In row 1 of the table the calculation is [Total] = [Volume] *
[Price]. In row 2 the calculation is [Total] = [Volume] * [Units] *
[UnitPrice]. In row 3 the calc is [Total] = [Volume] * [Charge] *
[PercentofCharge]. These formulas are hardcoded into the SELECT CASE
structure.
I would like to have a table with id and text fields with these formulas
loaded in the text field, then find the formula using the id and run it. This
would allow me to add new formulas on the fly. Can I do this?
I have a [CalcMethod] field and currently use a SELECT CASE structure to do
the calculation depending on the value in [CalcMethod] and place the value in
[Total]. ex. In row 1 of the table the calculation is [Total] = [Volume] *
[Price]. In row 2 the calculation is [Total] = [Volume] * [Units] *
[UnitPrice]. In row 3 the calc is [Total] = [Volume] * [Charge] *
[PercentofCharge]. These formulas are hardcoded into the SELECT CASE
structure.
I would like to have a table with id and text fields with these formulas
loaded in the text field, then find the formula using the id and run it. This
would allow me to add new formulas on the fly. Can I do this?