Count number of negative records in filtered Access 2010 form

Posted on 2012-09-06
Last Modified: 2012-09-06
I have a form that includes negative numbers.  I am using the following equation as the control source of a text box to count the number of negative records:


This does return the correct number of negative records.  However, when I filter the form, the number does not change.  Is there a way to count the number of negative records of the filter form?

Any ideas?
Question by:Scamquist
    LVL 29

    Accepted Solution

    I believe it would work if you just add a textbox in your form footer or header with this expression:
    =Sum(Iif([PEG_DAYS]<0, 1 0))
    LVL 1

    Author Comment

    Worked great.  Thanks.
    LVL 1

    Author Closing Comment

    I guess I tried to get too fancy.  Thank you for the assist.
    LVL 29

    Expert Comment

    You're quite welcome.

    Featured Post

    Looking for New Ways to Advertise?

    Engage with tech pros in our community with native advertising, as a Vendor Expert, and more.

    Join & Write a Comment

    We were having a lot of "Heartbeat Alerts" in our SCOM environment, now "Heartbeat" in a SCOM environment for those of you who might not be familiar with SCOM is a packet of data sent from the agent to the management server on a regular basis, basic…
    The System Center Operations Manager 2012, known as SCOM, is a part of the Microsoft system center product that provides the user with infrastructure monitoring and application performance monitoring. SCOM monitors:   Windows or UNIX/LinuxNetwo…
    Learn how to number pages in an Access report over each group. Activate two pass printing by referencing the pages property: Add code to the Page Footers OnFormat event to capture the pages as there occur for each group. Use the pages property to …
    Access reports are powerful and flexible. Learn how to create a query and then a grouped report using the wizard. Modify the report design after the wizard is done to make it look better. There will be another video to explain how to put the final p…

    755 members asked questions and received personalized solutions in the past 7 days.

    Join the community of 500,000 technology professionals and ask your questions.

    Join & Ask a Question

    Need Help in Real-Time?

    Connect with top rated Experts

    22 Experts available now in Live!

    Get 1:1 Help Now