Results 1 to 6 of 6
  1. #1
    Tuckejam is offline Competent Performer
    Windows 10 Access 2010 64bit
    Join Date
    Jan 2020
    Posts
    168

    Putting Total from different Query in a form

    Almost certainly going about this the wrong way but.....



    I have table with all the data from my checking account register including "TransAmount" and "Reconciled" Note: Reconciled is a checkbox.

    in the form that shows all of this data, at the top I Have the account balance which is all sum of all of the transactions.

    But I want the total of all of the transactions that have "Reconciled" checked yes (this way i can match this total to what my bank account shows)


    I created a new qry_BankBal that just has TransAmount and Reconciled summed and sorted to only show the sum on transacitons that have reconciled set to yes

    How do get this number into my form.

    Click image for larger version. 

Name:	Capture.PNG 
Views:	15 
Size:	16.5 KB 
ID:	43304

    as always, Thanks for the help

  2. #2
    Bob Fitz's Avatar
    Bob Fitz is offline Access Developer
    Windows 10 Access 2016
    Join Date
    May 2011
    Location
    Essex UK
    Posts
    3,544
    Try Following as Record Source of the text box:
    =DLookup("SumOfTrans","qry_BankBal")
    If this helped, please click the star at the bottom left of this posting and add to my reputation . Many thanks.
    Bob Fitzpatrick

  3. #3
    Tuckejam is offline Competent Performer
    Windows 10 Access 2010 64bit
    Join Date
    Jan 2020
    Posts
    168
    Genius! Thank You!

  4. #4
    Bob Fitz's Avatar
    Bob Fitz is offline Access Developer
    Windows 10 Access 2016
    Join Date
    May 2011
    Location
    Essex UK
    Posts
    3,544
    Genius! Thank You!
    Thank you for your kind words, but I can assure you that I am no genius. I am, however, always pleased to help if I can
    If this helped, please click the star at the bottom left of this posting and add to my reputation . Many thanks.
    Bob Fitzpatrick

  5. #5
    Join Date
    Jan 2017
    Location
    Swansea,South Wales,UK
    Posts
    4,940
    A DSum would have worked as well I expect?

  6. #6
    Bob Fitz's Avatar
    Bob Fitz is offline Access Developer
    Windows 10 Access 2016
    Join Date
    May 2011
    Location
    Essex UK
    Posts
    3,544
    A DSum would have worked as well I expect?
    I'd be surprised if it wouldn't
    Something like:
    Code:
    =DSum("TransAmount","YourTransactionTableName","Reconciled= -1")
    Wouldn't need the query with DSum(), of course.
    If this helped, please click the star at the bottom left of this posting and add to my reputation . Many thanks.
    Bob Fitzpatrick

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

Similar Threads

  1. Putting texbox Datasource string in a query
    By Paul H in forum Reports
    Replies: 15
    Last Post: 01-15-2021, 12:25 AM
  2. Replies: 3
    Last Post: 08-23-2019, 09:55 AM
  3. Replies: 3
    Last Post: 09-23-2017, 08:16 AM
  4. Putting a Form in Outlook Body
    By Minkyboodle in forum Import/Export Data
    Replies: 2
    Last Post: 04-13-2014, 08:19 PM
  5. Help with putting QUERY in a Range
    By taimysho0 in forum Programming
    Replies: 3
    Last Post: 02-15-2012, 06:29 PM

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