Access Option Group on Form

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
 
G

Guest

tried this IIf([Tax Rate]=1,"20%",IIf([Tax Rate]
=2,"40%",IIf([Tax Rate]=3,"Exempt",0)))
 
G

George Nicholson

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,
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top