Need help in Or/And function in creating report

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

Hello,

I am trying to create a report that calculate certain fields and add up the
total.
For example: in a Text Box field I have,
=Sum(IIf([Stage]<>3,[Time],0))
This is to say calculate the sum of time in all stages except stage 3. (3 is
one of 9 stages under StageID key field)

I would like to create the same expression, except to exclude time in stage
1 to 5.
How do I put in in expression form? I tried And or Or function, but have not
luck.

Any help is appreciated.
 
Try this

=Sum(IIf([Stage] not in(1,2,3,4,5),[Time],0))

Or
=Sum(IIf([Stage]>0 And [Stage] < 6,[Time],0))
 
Back
Top