IIF statement to calculate

  • Thread starter Thread starter Colleen
  • Start date Start date
C

Colleen

I have a RSVP report that I need to calculate the number of "yes" responses.
This is not a Yes/No field. I just free hand type YES or NO.

I want to sum the "yes" responses. Do I need to change this field to a
Yes/No field? This is what I have tried but it doesn't work and I'm not very
good at the "IIF statements". =IIf([RSVPGuest],Yes,1)

Thanks for your help.
Colleen
 
IT WORKED!!!!!!!!!!!! Thank you sooooo much. Don't know what "Abs" is but
thanks you.

Duane Hookom said:
Try:
=Abs(Sum([RSVPGuest]="Yes"))
--
Duane Hookom
Microsoft Access MVP


Colleen said:
I have a RSVP report that I need to calculate the number of "yes" responses.
This is not a Yes/No field. I just free hand type YES or NO.

I want to sum the "yes" responses. Do I need to change this field to a
Yes/No field? This is what I have tried but it doesn't work and I'm not very
good at the "IIF statements". =IIf([RSVPGuest],Yes,1)

Thanks for your help.
Colleen
 
It Means Absolute, or in other words makes a negative number into the
positive equivalent. In your example [RSVPGuest]="Yes" will either be True
(-1) or False (0)
so adding up all the -1's will give you a minus total. The Abs will turn
this into a positive total.

Colleen said:
IT WORKED!!!!!!!!!!!! Thank you sooooo much. Don't know what "Abs" is but
thanks you.

Duane Hookom said:
Try:
=Abs(Sum([RSVPGuest]="Yes"))
--
Duane Hookom
Microsoft Access MVP


Colleen said:
I have a RSVP report that I need to calculate the number of "yes" responses.
This is not a Yes/No field. I just free hand type YES or NO.

I want to sum the "yes" responses. Do I need to change this field to a
Yes/No field? This is what I have tried but it doesn't work and I'm not very
good at the "IIF statements". =IIf([RSVPGuest],Yes,1)

Thanks for your help.
Colleen
 
Back
Top