Results 1 to 9 of 9
  1. #1
    edg is offline Novice
    Windows 7 64bit Access 2007
    Join Date
    Jul 2014
    Posts
    14

    Checking boxes in form but always getting one less record

    I use a form to generate record specific reports - the table with the data has a check box field. If I check off 3 records, Only 2 reports show. If I check off 7, I get six reports. When I check the select query that sorts the data for the form, I find the correct number of check boxes - in the two examples noted, 3 and 7 respectively. The recordset is dynaset, the form is continuous and allows additions/deletions to allow for the checkbox activity. I'm probably missing a simple switch somewhere.

  2. #2
    pbaldy's Avatar
    pbaldy is offline Who is John Galt?
    Windows XP Access 2007
    Join Date
    Feb 2010
    Location
    Nevada, USA
    Posts
    22,518
    It sounds like you haven't moved off the last record, so the change isn't saved yet.

    You realize that method won't work very well in a multi-user environment.
    Paul (wino moderator)
    MS Access MVP 2007-2019
    www.BaldyWeb.com

  3. #3
    edg is offline Novice
    Windows 7 64bit Access 2007
    Join Date
    Jul 2014
    Posts
    14
    Not a multi user environment. I'm using check boxes simply to identify select records for printing select reports. The check boxes are cleared when I exit the form using an update query. Regardless of how many check boxes I tick, I'm always the report for the last check box ticked

  4. #4
    pbaldy's Avatar
    pbaldy is offline Who is John Galt?
    Windows XP Access 2007
    Join Date
    Feb 2010
    Location
    Nevada, USA
    Posts
    22,518
    Have you tried moving off the record of the last one ticked, or otherwise explicitly saving the record?
    Paul (wino moderator)
    MS Access MVP 2007-2019
    www.BaldyWeb.com

  5. #5
    edg is offline Novice
    Windows 7 64bit Access 2007
    Join Date
    Jul 2014
    Posts
    14
    The form is quite simple - continuous with two fields for each record - the record ID and a check box. There are 195 records and I scroll down checking the ones I want to produce a report. I just tried checking the first record only - and a report with no record number on it. If I check the first two records, I only get a report for the first one.

  6. #6
    pbaldy's Avatar
    pbaldy is offline Who is John Galt?
    Windows XP Access 2007
    Join Date
    Feb 2010
    Location
    Nevada, USA
    Posts
    22,518
    Have you tried checking a box, then clicking somewhere on a different record, then running the report? I'm trying to see whether the unsaved record is the problem. Clicking on a different record is one way of forcing a save. Can you attach the db here?
    Paul (wino moderator)
    MS Access MVP 2007-2019
    www.BaldyWeb.com

  7. #7
    edg is offline Novice
    Windows 7 64bit Access 2007
    Join Date
    Jul 2014
    Posts
    14
    Clicking away doesn't help - how do I attach the db - it is split, data in one, forms, etc in another.

  8. #8
    edg is offline Novice
    Windows 7 64bit Access 2007
    Join Date
    Jul 2014
    Posts
    14
    I solved the problem - had to add forms!(form name).refresh to update table/query to reflect selections made - works now - thanks!

  9. #9
    pbaldy's Avatar
    pbaldy is offline Who is John Galt?
    Windows XP Access 2007
    Join Date
    Feb 2010
    Location
    Nevada, USA
    Posts
    22,518
    Glad you got it sorted.
    Paul (wino moderator)
    MS Access MVP 2007-2019
    www.BaldyWeb.com

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

Similar Threads

  1. query not checking for newly created record
    By JWawrzak in forum Queries
    Replies: 3
    Last Post: 10-11-2016, 05:14 AM
  2. Replies: 2
    Last Post: 07-21-2015, 05:09 AM
  3. Replies: 7
    Last Post: 07-01-2015, 10:29 AM
  4. Error Checking Boxes
    By CementCarver in forum Access
    Replies: 2
    Last Post: 06-12-2013, 04:27 PM
  5. Checking a record in a table
    By widstje in forum Programming
    Replies: 4
    Last Post: 11-07-2007, 11:28 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