Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chris Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

iif statement

Status
Not open for further replies.

pleasehelpalot

Instructor
Oct 4, 2005
92
US
I have a report with a Date Opened field. I want to check a box if the claim is within 60 days of the Opened Date. I'm trying to use an iif statement but it doesn't work. I'm not a programmer so i can use some help.
Here's what i have:

IIf ("DateOpened" <= Date() - 60, Check1 (1), Check1 (0))

What's wrong as it produces a compile error - Expected:=

Thanks
 


hi,


Code:
YourCkBox.Value = IIf  ([DateOpened] <=  Date() - 60, Check1(1), Check1(0))


Skip,
[sub]
[glasses]Just traded in my old subtlety...
for a NUANCE![tongue][/sub]
 

Wouldn't it be:
Code:
YourCkBox.Value = IIf ([DateOpened] <= Date() - 60, 1, 0)
?

Have fun.

---- Andy
 
Thanks Skip, but now the message says:
"You entered an expression that has no value
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top