Buttons in forms to filter report data (1 Viewer)

  • Thread starter Deleted member 134417
  • Start date
D

Deleted member 134417

Guest
Hey guys,
I want to create a navigation form, or any form for that matter that has an embedded report. The report has data arranged by ClientID. I would like to create buttons down the left side of my form (why I thought a navigation form could work) where I can put the client name on the buttons and when I click them the report will filter to only show that clients data. Any suggestions? I have client tables and the report data linked in queries, but just need to know how to get started with these buttons acting as ID sorters.
For example:
ClientID: 1 = Client: ABC Corp
In my report ClientID 1's data is grouped along with all other client ID's.
In my form I'd like buttons down the left side with ABC Corp written on it (followed by buttons for the other clients) and then when I click the ABC Corp button only ABC Corp's data shows on the page from the embedded report
I hope that makes sense
Cheers
 

Uncle Gizmo

Nifty Access Guy
Staff member
Local time
Today, 04:41
Joined
Jul 9, 2003
Messages
16,331
How many clients have you got? And what happens if you get a new client?
 
D

Deleted member 134417

Guest
How many clients have you got? And what happens if you get a new client?
I currently have 45 clients (which are actually staff). This will only change by 3 - 5 each year but will always remain at 45. So from year to year I'm thinking i'd just change the buttons from those who have left to those who have come in.
I'm currently watching some tutorials on the 'browse to' function and using the clientID for each button in the 'where condition' section...
Any advice, thoughts?
 

Uncle Gizmo

Nifty Access Guy
Staff member
Local time
Today, 04:41
Joined
Jul 9, 2003
Messages
16,331
I am not sure about a 45 button interface, especially as you cannot guarantee that the numbers will remain at 45.

A much better solution would be a combobox where you select the staff member.

One reason this is better is that if the combobox is linked to a lookup table of staff members then you can control which staff appear in the combo box by adding a checkbox to identify current staff members. This is simple, it's the way it's done, and it works.

If you want to go the command button route, editing the buttons when a staff member changes is not an option you should consider.

You should come up with a way to programmatically assign a name to each command button from the list of staff members this would not necessarily be difficult but you will need to do some VBA code.
 

Users who are viewing this thread

Top Bottom