Results 1 to 3 of 3
  1. #1
    ariansman is offline Advanced Beginner
    Windows 7 64bit Access 2010 64bit
    Join Date
    Apr 2013
    Posts
    57

    How to get an instant sum

    I have the following form based on a table:


    Code:
    empName             salary            working
    jack                     1000              yes/no
    Steve                   1500               yes/no
    Janet                   200                yes/no
    summary:  [number]
    fields “empname” and”salary” are locked, but the working is field is able the be switched between “yes” and “No” by the operator by a click.

    Is it possible that the "summary" shows the instant sum of salaries of the employs whose working status is “yes”? For example all “working” are yes and summary shows 2700. But the operator clicks on the working status of Steve and changes it to NO, and the summary right away shows 1200.

    i am not sure if this is doable on a form or report.
    thank you

  2. #2
    JoeM is offline VIP
    Windows 7 32bit Access 2007
    Join Date
    Jun 2012
    Posts
    3,904
    The "summary" should be a calculated text box in the Form Footer section.
    Use this as the Control Source to get it to do what you want:
    Code:
    =Sum(IIf([working],[salary],0))
    It will update as soon as you move off the record you just updated (so it moves from "edit" to"submitted" status).

  3. #3
    June7's Avatar
    June7 is offline VIP
    Windows 10 Access 2010 32bit
    Join Date
    May 2011
    Location
    The Great Land
    Posts
    52,931
    How to attach file: http://www.accessforums.net/showthread.php?t=70301 To provide db: copy, remove confidential data, run compact & repair, zip w/Windows Compression.

Please reply to this thread with any new information or opinions.

Similar Threads

  1. Looking for access friend that has instant messanger. $5 per query
    By undefatedskillz26 in forum General Chat
    Replies: 2
    Last Post: 12-24-2014, 08:09 AM
  2. Instant Search in Navigation Bar
    By EddieN1 in forum Forms
    Replies: 2
    Last Post: 02-25-2014, 07:53 PM
  3. Instant Search with textbox in Form
    By MrBeardo in forum Queries
    Replies: 1
    Last Post: 03-28-2012, 02:08 PM
  4. Instant load of a form
    By carstenhdk in forum Forms
    Replies: 2
    Last Post: 05-06-2010, 12:27 AM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Other Forums: Microsoft Office Forums