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 question with "where" clause? 1

Status
Not open for further replies.

meldrape

Programmer
May 12, 2001
516
US
Hi there,

I have a timesheet report and I'm trying to breakout totals in the report footer. I already have a grand total, a regular time total and over time total, but now I need a "personal time" total. The field is "task" and the task is PTO. So I need it to do the following:

=iif ([task]="PTO",sum([hours]),"0.00")

THis isn't working. I have some test data for 2.5 hours for the task PTO and it's not finding it. I know my syntax isn't correct. I'd very much appreciate any ideas. Thank you very much in advance.
 
Try the DSum function. Try something like this as the control source:
Code:
=DSum("[hours]","YourQuery","[task] = 'PTO'")
 
thanks, Cosmo. I will try that. I found another one of your threads just a few minutes ago, where you created an invisible text box in one footer then called it again in the report footer. I'll try both methods. Thanks again.

 
Your suggestion worked great. Thanks for your help.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top