Help with an Expression

  • Thread starter MichelleM via AccessMonster.com
  • Start date
M

MichelleM via AccessMonster.com

Here's my situation. I have a parameter query (for date specific) set up to
track all inbound and outbound calls. Call Direction is the column heading
that states if the call was inbound or outbound. I'm trying to create a
report to do 3 things:
1. Give me the total contacts (Inbound and Outbound)
2. Give me the total of just Inbound
3. Give me the total of just Outbound

I have the total contacts text box set up and working, but now I'm stuck on
how to set up another text box to just bring back the total of the Inbound
contacts.

Here is my expression for the total

=Sum([qryBSC Inbound/Outbound Calls]!CountOfCallDirection)

I'm assuming I have to add in something with the CallDirection=Inbound, but
since I'm newer to Access and not real experienced with expressions, I'm
stuck. Any suggestions, would be great! Thanks!
 
J

John Spencer

What value is stored in CallDirection?
Is it a number, text (Inbound), a boolean value (true/false)?

Perhaps you could share the SQL of the query you are using to generate the
data for the report?

Do you have the field CallDirection in your report?

If so, and it holds the word "Inbound" then

=Sum(IIF(CallDirection="Inbound",CountOfCallDirection,Null))
and
=Sum(IIF(CallDirection="Outbound",CountOfCallDirection,Null))



John Spencer
Access MVP 2002-2005, 2007-2008
The Hilltop Institute
University of Maryland Baltimore County
 
M

MichelleM via AccessMonster.com

This worked! Thank you so much!

John said:
What value is stored in CallDirection?
Is it a number, text (Inbound), a boolean value (true/false)?

Perhaps you could share the SQL of the query you are using to generate the
data for the report?

Do you have the field CallDirection in your report?

If so, and it holds the word "Inbound" then

=Sum(IIF(CallDirection="Inbound",CountOfCallDirection,Null))
and
=Sum(IIF(CallDirection="Outbound",CountOfCallDirection,Null))

John Spencer
Access MVP 2002-2005, 2007-2008
The Hilltop Institute
University of Maryland Baltimore County
Here's my situation. I have a parameter query (for date specific) set up to
track all inbound and outbound calls. Call Direction is the column heading
[quoted text clipped - 15 lines]
since I'm newer to Access and not real experienced with expressions, I'm
stuck. Any suggestions, would be great! Thanks!
 
Top