View Full Version : Setting values of one object based on the value of another object


kryptkitten
07-19-2010, 10:23 AM
Hi All,

I have a report in Access 2000 where I am working with two text boxes that I am trying to set some values for so essentially here is the scenario:

if textbox1=0 then I want textbox2 to display N/A
if textbox1=-1 then then I want textbox2 to display the value I have set as the control source for textbox2.

So how do I go about doing this?

Thanks so much!

Stacy

pbaldy
07-19-2010, 11:07 AM
Try a control source of:

=IIf(OneFieldName = 0, "N/A", OtherFieldName)

kryptkitten
07-19-2010, 11:20 AM
That worked beautifully! Thank you!

pbaldy
07-19-2010, 12:04 PM
No problemo!