Still celebrating National IT Professionals Day with 3 months of free Premium Membership. Use Code ITDAY17

x
?
Solved

Unbound check box in microsoft access form

Posted on 2013-12-07
5
Medium Priority
?
2,408 Views
Last Modified: 2013-12-08
I have multi-record access form that has an unbound check box. When I select any of the check boxes they are all marked as selected. I need to somehow identify a certain record so that I can use other field values of the record to create a query tied to a button on the form. Can the unbound check box be used to identify a specific record or is there a better way to identify a record for use as a parameter in a query?
0
Comment
Question by:PetGuy
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 3
  • 2
5 Comments
 
LVL 58

Accepted Solution

by:
Jim Dettman (Microsoft MVP/ EE MVE) earned 2000 total points
ID: 39703676
This is a common problem.   Your best bet is to add a "Selection table", which has a field for the primary key of your record..

Add this table to the query for your form, join on the primary key, and then double click on the line and make it an outer join.

You can then define a column in the query as:

Not IsNull(<selection key field>)

Then use a transparent command button over the check box to toggle the state of the checkbox by adding/deleting records in the selection table.

  The other method if you only need to select a single record is use the Primary Key field as part of a WHERE clause for a form or report.

Jim.
0
 

Author Comment

by:PetGuy
ID: 39703690
Thanks for the point in the right direction. And fast.
0
 

Author Comment

by:PetGuy
ID: 39703715
How do I do a transparent command button. It is totally new to me.
0
 
LVL 58
ID: 39704227
<<How do I do a transparent command button. It is totally new to me. >>

 Set the Transparent property to Yes.  Then place the control and do a "Bring to Front" on the arrange menu.

This places it "on top" of the check box and it will receive the click rather then the check box.   Besides the normal top/bottom, left/right positioning, there is also a Z order to controls (3rd axis).   The "send to back" and "bring to front" are the two commands that work with this and control what is seen when controls are stacked on top of one another.

Make sure it's big enough that it covers the checkbox.  Also, you should set the enabled property to false and the locked property to true on the checkbox.

Jim.
0
 

Author Comment

by:PetGuy
ID: 39704582
thanks
0

Featured Post

What does it mean to be "Always On"?

Is your cloud always on? With an Always On cloud you won't have to worry about downtime for maintenance or software application code updates, ensuring that your bottom line isn't affected.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

This article shows how to get a list of available printers for display in a drop-down list, and then to use the selected printer to print an Access report or a Word document filled with Access data, using different syntax as needed for working with …
Code that checks the QuickBooks schema table for non-updateable fields and then disables those controls on a form so users don't try to update them.
Using Microsoft Access, learn some simple rules for how to construct tables in a relational database. Split up all multi-value fields into single values: Split up fields that belong to other things into separate tables: Make sure that all record…
With Microsoft Access, learn how to specify relationships between tables and set various options on the relationship. Add the tables: Create the relationship: Decide if you’re going to set referential integrity: Decide if you want cascade upda…

670 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question