Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chris Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Show all records option on a subform

Status
Not open for further replies.

rilkyn

Technical User
Jan 19, 2005
33
GB
Hi

I've been trying to figure this out for some time but have not managed it. I am using Access '97.

I have a subform within a form with a combo box built to find specific sets of records. The subform is continuous. I have been trying, with no luck to add the option of showing all records on the subform. I can add the <All> value to the combo box list and thought the following would work but it doesn't.

If Me![Combo61] = "<All>" Then
Me.Requery
Me.RecordsetClone.FindFirst "[Access ID Name] like '*' "
Me.Bookmark = Me.RecordsetClone.Bookmark

Else
Me.Requery
Me.RecordsetClone.FindFirst "[Access ID Name] = '" & Me![Combo61] & "'"
Me.Bookmark = Me.RecordsetClone.Bookmark

End If

I've tried both the union query method and the module listed on the Microsoft website but could not get either to work.
 
How are ya rilkyn . . .

The function of your combobox is to find a record among [blue]all[/blue] those returned by the recordsource of the form. [blue]Your already showing all records![/blue]

You'll have to explain better! . . .

Calvin.gif
See Ya! . . . . . .

Be sure to see FAQ219-2884:
 
I effectively want to disable the function so that rather than find one group of records, I bring back a list of all records regardless of their grouping (the combo box would list the group names in the example below). It is useful if the user is looking for a record but does not know which category it is in.

eg

Group record

Group A Alfie
Group A John
Group A Richard
Group B Andrew
Group B Craig
Group C George
Group C Bertie

If the user knows the record details he/she is after is 'Craig', for instance but does not know which group it is associated with, he/she wants to option to list all the records on the subform rather than going into each category to find which one it is in. They can then use the scroll bar to quickly get to the desired record.











 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top