Sellecting records from a list

Brando

Enthusiastic Novice
Local time
Yesterday, 23:38
Joined
Apr 4, 2006
Messages
100
I've searched and searched, but not sure if I'm using the right search terms...

I have a search form that looks up records in a table and displays them on a subform (maybe I should display them in a listbox instead). Anyway, I want to be able to look down the list of results and click on various records to further narrow the data set. I once saw a sample database that had that amazing function, but now I can't find it. Arrrrgh. As I recall, it appended records temporarily to a table.

Anyone know where I might learn about such a thing?


Thank you in advance,

Brando
 
I'm not clear on what you mean by further narrowing, but a multiselect listbox is probably how I'd let the user make selections. What are you expecting to happen when/as they make selections?
 
Paul,
The list of records that result from the search (which include a sale price) need to be looked over by the user who will then select a few of them. The user will then click on a command button that will average the sale prices of the selected records in a text box. Ideal would be to have a check box next each record in the list and then have a button that will look up the selected records only, removing the records that aren't checked.

Make sense?
 
Well, the first part I'd still do with a listbox. You can loop the selected items grabbing the values and then calculate the average. If you want a subform with checkboxes, the checkbox field would need to be bound to the underlying data. Doable, but probably more work.
 
Check boxes are just so intuitive for users! Okay, so I've added a check box to the table data called "Select", and I've checked the box in each record. So when the subform displays the search results, all of the records will be checked (and factored into the average). The user will have to uncheck any records that they don't want to be factored into the average.

When the user starts a new search, is there a way to have all of the unchecked records in the table put back to checked (or "Yes")?
 
Check boxes are just so intuitive for users! Okay, so I've added a check box to the table data called "Select",

Better change that to singular, "user". Either that or you will need a separate table for each user.

BTW Select is not a good name for a field for obvious reasons.
 
Galaxiom,
Why would each user need a separate table? Am I going about this all wrong?

Brando
 
If you add the Boolean field to the table and two users are selecting at the same time they will get each other's selections. Some developers use a temporary table for the user which is probably the function you have seen before.

Another way to do this is with a disconnected ADO recordset but it is quite complex to implement.
 
In a multi-user environment, one user can change another user's settings if the data is in a single table (which it normally is).
 
Sorry Galaxiom, I thought your light showed you offline.
 

Users who are viewing this thread

Back
Top Bottom