New to Access and need a little help getting started

  • Thread starter Thread starter Steven Davidson
  • Start date Start date
S

Steven Davidson

I'm playing around with Access 2007 and I'm starting it off with creating a
password database. I created two tables. One table is a client table that
has only two fields. The first field is an index field. The second field is
ClientName. The other table is a password table. This table has several
fields and a relationship to the client table. What I want to be able to do
is have a view that allows me to view the records and filter by client so
that I can see only those records which belong to the client I'm interested
in viewing. I figured that I'd have to create a report for that. For the
life of me, I cannot figure out how I'm going to get it so that I have a
combo box which lists all of the clients and then, when I select a client
from the list, the report would refresh and show only those records which
belong to that client. I tried to add a combobox to the report I created but
it didn't have a dropdown arrow and whatever I typed into it would disappear
as soon as I tabbed off the control. Is a report the way to do this?
 
Steven said:
I'm playing around with Access 2007 and I'm starting it off with creating a
password database. I created two tables. One table is a client table that
has only two fields. The first field is an index field. The second field is
ClientName. The other table is a password table. This table has several
fields and a relationship to the client table. What I want to be able to do
is have a view that allows me to view the records and filter by client so
that I can see only those records which belong to the client I'm interested
in viewing. I figured that I'd have to create a report for that. For the
life of me, I cannot figure out how I'm going to get it so that I have a
combo box which lists all of the clients and then, when I select a client
from the list, the report would refresh and show only those records which
belong to that client. I tried to add a combobox to the report I created but
it didn't have a dropdown arrow and whatever I typed into it would disappear
as soon as I tabbed off the control. Is a report the way to do this?


I have something similar, but I'm using a form instead of a report.
Combo boxes only work in forms. (Access does allow "lookup" fields in
tables, but that's generally seen as a Bad Idea.) Reports are for
printing; forms are for on-screen stuff.

I've run out of time looking for a good reference for what you need to
do (pizza just arrived!) but you might find this useful:

http://files.lynda.com/files/marketing/microsoft/07_07_AC_sortfilter.mov

Phil, London
 
What I want to be able to do
is have a view that allows me to view the records and filter by client so
that I can see only those records which belong to the client I'm interested
in viewing.

Use a Form (not a report, reports are for printing, forms for viewing and
interacting with data) based on the Clients table, with a Subform based on the
password table; use the ClientID (or linking field) as the subform's
master/child link field. This will let you see each client's information in
conjunction with that client's name.

I would suggest using a few more fields in your clients table: LastName and
FirstName rather than storing both names in one field, probably static contact
information such as address, etc. can all go in the parent table.
 
Why do you think you need to create a report to view records? You should be
able to use a continuous subform.

I would have a main form with the combo box (name it "cboClient").

Create a subform based on your password table. Add the subform to the main
form. Then set the Link properties on your subform control like:
Link Master: cboClient
Link Child: [related field with an unknown name]
 
Philip said:
I have something similar, but I'm using a form instead of a report.
Combo boxes only work in forms. (Access does allow "lookup" fields in
tables, but that's generally seen as a Bad Idea.) Reports are for
printing; forms are for on-screen stuff.

I've run out of time looking for a good reference for what you need to
do (pizza just arrived!) but you might find this useful:

http://files.lynda.com/files/marketing/microsoft/07_07_AC_sortfilter.mov

Phil, London

Came back here to pick up my erratically incomplete answer, but I see
you've had considered replies from three of our most respected
contributors, so there's little I need add. I'll have to resist the
temptation to rush off an answer when there isn't time to be clear and
complete. Had I not paid attention to the pizza when it arrived I'd
quickly have found myself wearing it...

Phil
 
Hi Steven

It is easy you just create another query with fields of your both
tables(combine both table in a query). Now go to the design view of this
query and on client name column at Criteria row define parameter by typing
[Enter Client Name] thats all. Save and exit.

Now open the query , a pop window will appear with message enter client name
, you just enter the name you wish and see the result.

You can use same query for your report to show desired record.
 
Back
Top