Results 1 to 8 of 8
  1. #1
    googalabosh is offline Advanced Beginner
    Windows 10 Access 2016
    Join Date
    Sep 2017
    Posts
    48

    Total records count on report

    I want to add a text box to my report that will count the total number of records from a table and display that total.



    How do I do this?

  2. #2
    Gicu's Avatar
    Gicu is offline VIP
    Windows 8 Access 2013
    Join Date
    Jul 2015
    Location
    Kelowna, BC, Canada
    Posts
    4,101
    Put something like this in the control source: =dcount("*",[YourTableName])

    Cheers,
    Vlad

  3. #3
    googalabosh is offline Advanced Beginner
    Windows 10 Access 2016
    Join Date
    Sep 2017
    Posts
    48
    Quote Originally Posted by Gicu View Post
    Put something like this in the control source: =dcount("*",[YourTableName])

    Cheers,
    Vlad
    Thanks! I tried that but it's giving me a "#Name?" error.

  4. #4
    Gicu's Avatar
    Gicu is offline VIP
    Windows 8 Access 2013
    Join Date
    Jul 2015
    Location
    Kelowna, BC, Canada
    Posts
    4,101
    Have you checked the spelling of the table name? Can you show a picture with the design view and the properties sheet?

  5. #5
    Beetle is offline Unrelatable
    Windows 7 64bit Access 2010 32bit
    Join Date
    May 2011
    Location
    Camp Swampy (Denver, CO)
    Posts
    207
    Make sure you put the table name in quotes;

    =DCount("*", "YourTable")

  6. #6
    googalabosh is offline Advanced Beginner
    Windows 10 Access 2016
    Join Date
    Sep 2017
    Posts
    48
    Gicu,
    I'm unable to share it with you. I really wish I could. Sorry.


    Beetle,
    I added the quotes around the table name, however, now the error just says "#Error".

  7. #7
    googalabosh is offline Advanced Beginner
    Windows 10 Access 2016
    Join Date
    Sep 2017
    Posts
    48
    I figured out my problem. I needed the quotes but I was referring the column in the table rather than the table itself.

    Thanks to both of you!

  8. #8
    Gicu's Avatar
    Gicu is offline VIP
    Windows 8 Access 2013
    Join Date
    Jul 2015
    Location
    Kelowna, BC, Canada
    Posts
    4,101
    Glad to hear!

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

Similar Threads

  1. OnClick event to view Total Count records
    By wnicole in forum Forms
    Replies: 5
    Last Post: 11-16-2015, 11:55 AM
  2. Replies: 11
    Last Post: 05-09-2014, 12:00 PM
  3. Replies: 6
    Last Post: 02-23-2014, 03:54 PM
  4. Replies: 8
    Last Post: 06-13-2013, 06:49 AM
  5. Replies: 1
    Last Post: 01-24-2013, 05:50 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