Access Option Group on Form

  • Thread starter Thread starter Ann
  • Start date Start date
A

Ann

Hi

I figured out how to assign the Control Source from my
Option Group to my table so now if I click on the 20%
option I get 1 back in the table, if I click on the 40%
option I get 2 and if I click on the Exempt option I get
3. I now need to query this to show Tax % in a new field.
I have tried using iif([Tax Rate]=1,20%,iif([Tax Rate]
=2,40%,"exempt")) but this is giving me error# in each
cell.

I have:

Name Dept Tax Rate Tax %
Ann Training 1 (coming from I want this to show 20%
the option 40% or Exempt
on the form)

Any help would be greatly appreciated1

Thanks in advance

Ann
 
Hi Ann:

I assume you are trying to pass a string? ([Tax%] is a Text field, right?)
Try:

iif([Tax Rate]=1, "20%", iif([Tax Rate] =2, "40%", "exempt"))

(i.e., enclose 20% and 40% in quotes.)

If [Tax%] is a number field, don't try to pass the percent sign and change
"Exempt" to a numerical value:
iif([Tax Rate]=1, 0.2, iif([Tax Rate] =2, 0.4, 0))

Hope this helps,
 
Back
Top