Making a searchable access database

  • Thread starter Thread starter Andrew
  • Start date Start date
A

Andrew

Im fairly new to access so please bear with me. We resell webhosting and I
want to make a database of our clients with their domains, user ids,
passwords etc. I want to make this searchable so that I can pull up the
record that contains their data if I need to. How would I go about doing
this? Is there a tutorial on making a searchable database?

Thanks
 
Andrew,

Access, as most any database, is inherently searchable. If
you store your data 'properly' in tables, it is easy to
create a form to display/enter/edit the data. The combobox
wizard can then help you create one or more comboboxes you
can drop in the form header that will find a record base on
your selection from all of the available records.

Take a look at the sample Northwind database that comes with
Access and you will get some ideas. When you have some
specific questions, come on back.

--

Gary Miller
Gary Miller Computer Services
Sisters, OR
________________________
 
Thanks

I have already figured out how to make a combo box in the header that has
all the data in the table so I can type in a name or whatever and it will
bring it up - when I hit enter however I would like the data to be displayed
in a form in the body of the form.
Thats step one - ill bug you for more when I get that figured out :)

Andrew
 
Hi,
I have already figured out how to make a combo box in the header that has
all the data in the table so I can type in a name or whatever and it will
bring it up - when I hit enter however I would like the data to be displayed
in a form in the body of the form.
Thats step one - ill bug you for more when I get that figured out :)

You can set RecordSource for your combo to an SQL statement who retrieves
all required fields. Set the combo-box as multi-column (so when you open
drop-down list you'll see all fields in a sort of table. Then you can put
several unbound controls on your form (in the body), and bound them to
columns in the combo box.

This way, when you select something in the combo, the fields from the form
will be updated.

Another approach is to bind the form to the table itself, except for search
box.
In AfterUpdate event for the searchbox, you should write a code to search
the form's recorset for a record who match the data entered by user, and set
current record to it.

Regards,
Bogdan
 
Andrew,

As I was saying, the combo wizard can automate this. Here is
sample code for going to the record that you want. You would
put this in the AfterUpdate event of the combobox and then
change the combo reference to match the name of your combo
control and fields....

If your data is text....

Me.RecordsetClone.FindFirst "[Customer ID] = '" &
Me![YourComboName] & "'"
Me.Bookmark = Me.RecordsetClone.Bookmark

If it is numeric....

Me.RecordsetClone.FindFirst "[Customer ID] = " &
Me![YourComboName]
Me.Bookmark = Me.RecordsetClone.Bookmark
--

Gary Miller
Gary Miller Computer Services
Sisters, OR
________________________
 
I see what your saying Gary but im not quite sure how it all works

I used the combo wizard to make my search box
My combo box is called searchbox and everything displays properly there, all
the records are showing up etc

the first 2 colums in my table are name and company
I put a textbox for each in the body of the form

my records are text so i put this in the afterupdate event of the combobox

Private Sub SearchBox_AfterUpdate()
Me.RecordsetClone.FindFirst "[Name] = '" & Me![SearchBox] & "'"
Me.Bookmark = Me.RecordsetClone.Bookmark
End Sub

no what do i put in the text boxes to make them display the data?

am I headed in the right direction with this?

Thanks



Gary Miller said:
Andrew,

As I was saying, the combo wizard can automate this. Here is
sample code for going to the record that you want. You would
put this in the AfterUpdate event of the combobox and then
change the combo reference to match the name of your combo
control and fields....

If your data is text....

Me.RecordsetClone.FindFirst "[Customer ID] = '" &
Me![YourComboName] & "'"
Me.Bookmark = Me.RecordsetClone.Bookmark

If it is numeric....

Me.RecordsetClone.FindFirst "[Customer ID] = " &
Me![YourComboName]
Me.Bookmark = Me.RecordsetClone.Bookmark
--

Gary Miller
Gary Miller Computer Services
Sisters, OR
________________________
Andrew said:
Thanks

I have already figured out how to make a combo box in the header that has
all the data in the table so I can type in a name or whatever and it will
bring it up - when I hit enter however I would like the data to be displayed
in a form in the body of the form.
Thats step one - ill bug you for more when I get that figured out :)

Andrew
 
I answered my own question and it was all with the wizards - no manual
coding

I had to use the form wizard to make a form from my table - then when i did
the combo wizard there was an extra option to find a record based on my form
etc etc - thanks guys
Andrew said:
I see what your saying Gary but im not quite sure how it all works

I used the combo wizard to make my search box
My combo box is called searchbox and everything displays properly there, all
the records are showing up etc

the first 2 colums in my table are name and company
I put a textbox for each in the body of the form

my records are text so i put this in the afterupdate event of the combobox

Private Sub SearchBox_AfterUpdate()
Me.RecordsetClone.FindFirst "[Name] = '" & Me![SearchBox] & "'"
Me.Bookmark = Me.RecordsetClone.Bookmark
End Sub

no what do i put in the text boxes to make them display the data?

am I headed in the right direction with this?

Thanks



Gary Miller said:
Andrew,

As I was saying, the combo wizard can automate this. Here is
sample code for going to the record that you want. You would
put this in the AfterUpdate event of the combobox and then
change the combo reference to match the name of your combo
control and fields....

If your data is text....

Me.RecordsetClone.FindFirst "[Customer ID] = '" &
Me![YourComboName] & "'"
Me.Bookmark = Me.RecordsetClone.Bookmark

If it is numeric....

Me.RecordsetClone.FindFirst "[Customer ID] = " &
Me![YourComboName]
Me.Bookmark = Me.RecordsetClone.Bookmark
--

Gary Miller
Gary Miller Computer Services
Sisters, OR
________________________
Andrew said:
Thanks

I have already figured out how to make a combo box in the header that has
all the data in the table so I can type in a name or whatever and it will
bring it up - when I hit enter however I would like the data to be displayed
in a form in the body of the form.
Thats step one - ill bug you for more when I get that figured out :)

Andrew
Andrew,

Access, as most any database, is inherently searchable. If
you store your data 'properly' in tables, it is easy to
create a form to display/enter/edit the data. The combobox
wizard can then help you create one or more comboboxes you
can drop in the form header that will find a record base on
your selection from all of the available records.

Take a look at the sample Northwind database that comes with
Access and you will get some ideas. When you have some
specific questions, come on back.

--

Gary Miller
Gary Miller Computer Services
Sisters, OR
________________________
Im fairly new to access so please bear with me. We resell
webhosting and I
want to make a database of our clients with their domains,
user ids,
passwords etc. I want to make this searchable so that I
can pull up the
record that contains their data if I need to. How would I
go about doing
this? Is there a tutorial on making a searchable database?

Thanks
 
Glad you figured it out before I had a chance to get back to
you.

--

Gary Miller
Gary Miller Computer Services
Sisters, OR
________________________
Andrew said:
I answered my own question and it was all with the wizards - no manual
coding

I had to use the form wizard to make a form from my table - then when i did
the combo wizard there was an extra option to find a record based on my form
etc etc - thanks guys
Andrew said:
I see what your saying Gary but im not quite sure how it all works

I used the combo wizard to make my search box
My combo box is called searchbox and everything displays
properly there,
all
the records are showing up etc

the first 2 colums in my table are name and company
I put a textbox for each in the body of the form

my records are text so i put this in the afterupdate event of the combobox

Private Sub SearchBox_AfterUpdate()
Me.RecordsetClone.FindFirst "[Name] = '" & Me![SearchBox] & "'"
Me.Bookmark = Me.RecordsetClone.Bookmark
End Sub

no what do i put in the text boxes to make them display the data?

am I headed in the right direction with this?

Thanks



Andrew,

As I was saying, the combo wizard can automate this. Here is
sample code for going to the record that you want. You would
put this in the AfterUpdate event of the combobox and then
change the combo reference to match the name of your combo
control and fields....

If your data is text....

Me.RecordsetClone.FindFirst "[Customer ID] = '" &
Me![YourComboName] & "'"
Me.Bookmark = Me.RecordsetClone.Bookmark

If it is numeric....

Me.RecordsetClone.FindFirst "[Customer ID] = " &
Me![YourComboName]
Me.Bookmark = Me.RecordsetClone.Bookmark
--

Gary Miller
Gary Miller Computer Services
Sisters, OR
________________________
Thanks

I have already figured out how to make a combo box in the
header that has
all the data in the table so I can type in a name or
whatever and it will
bring it up - when I hit enter however I would like the
data to be displayed
in a form in the body of the form.
Thats step one - ill bug you for more when I get that
figured out :)

Andrew
message
Andrew,

Access, as most any database, is inherently searchable.
If
you store your data 'properly' in tables, it is easy to
create a form to display/enter/edit the data. The
combobox
wizard can then help you create one or more comboboxes
you
can drop in the form header that will find a record base
on
your selection from all of the available records.

Take a look at the sample Northwind database that comes
with
Access and you will get some ideas. When you have some
specific questions, come on back.

--

Gary Miller
Gary Miller Computer Services
Sisters, OR
________________________
Im fairly new to access so please bear with me. We
resell
webhosting and I
want to make a database of our clients with their
domains,
user ids,
passwords etc. I want to make this searchable so that
I
can pull up the
record that contains their data if I need to. How
would I
go about doing
this? Is there a tutorial on making a searchable
database?

Thanks
 
Back
Top