Results 1 to 3 of 3
  1. #1
    Nikh is offline Novice
    Windows 8 Access 2013 64bit
    Join Date
    Apr 2016
    Posts
    19

    How to Show Check Box With Distinct Value From Table on Form

    Hi..,

    I want to show Distinct value on Checkbox ...and also update checkbox automatically..When i use query


    i.1 First Time used query then found 10 records then form display 10 Checkbox
    2nd time distinct count is 15 then 15 checkbox should be display

  2. #2
    ItsMe's Avatar
    ItsMe is offline Sometimes Helpful
    Windows 8 Access 2013
    Join Date
    Aug 2013
    Posts
    7,862
    Perhaps you can generate a DAO recordset and iterate through the dataset to update records as necessary. Another approach might be to use SQL and the IN operator against a SELECT Statement.

  3. #3
    John_G is offline VIP
    Windows 7 32bit Access 2010 32bit
    Join Date
    Oct 2011
    Location
    Ottawa, ON (area)
    Posts
    2,615
    It sounds like you are describing a kind of one-to-many relationship. For what you want to do, you would be better off to use a main form - sub-form arrangement.

    If you try to use just checkboxes on one form, you cannot easily relate any one checkbox to a specific record; you would need VBA to a) populate and display the checkboxes in response to the query, b) keep track of which record each checkbox corresponded to, and c) update the records corresponding to the checkboxes after you made changes.

    The main form - subform corresponds better to the way databases and Access work.

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

Similar Threads

  1. Query will not show distinct lines
    By zbaker in forum Queries
    Replies: 2
    Last Post: 01-20-2015, 02:24 PM
  2. Replies: 1
    Last Post: 04-26-2013, 05:30 PM
  3. Replies: 4
    Last Post: 11-26-2012, 07:17 AM
  4. Check-box to hide/show input fields
    By RapidFireGT in forum Forms
    Replies: 2
    Last Post: 12-05-2011, 05:55 PM
  5. Replies: 5
    Last Post: 05-26-2010, 07:13 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