opening form to a particular record

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

With help I've worked out one of my major problems, now onto something minor.
For each entry into my table I give it a private catalog number (which is not
the table key). I would like to create a form that would ask for this number
then use it to display te corresponding information in the table (or from a
query) in new form that opens.
Thanks
 
David,
I think what you want is something I call a "Combo Quick Find". Using a
combobox on your form, that lists every PrivateCatNo in your recordset...
the user selects a PrivateCatNo... and you are taken to that specific record
within the recordset.
On my website (below) I have a sample 97 and 2003 file that shows how to
do that.
--
hth
Al Campagna
Microsoft Access MVP
Candia Computer Consulting
http://home.comcast.net/~cccsolutions/index.html
"Find a job that you love... and you'll never work a day in your life."
 
David,

If this is a followup question to my first recommendation, in the second
form with the textboxes, if you are displaying the catalog number put the
following code in the click event of that field. If you are not displaying
the catalog number, add it to your form and set its visible property to
False then put the following code in the clck event of one of the other
fields.
DoCmd.OpenForm "NameOfFirstForm",,"[CatalogNumber] = "'" &
Forms!NameOfSecondForm!CatalogNumber & "'"

The above assumes that CatalogNumber is text. If it is numeric, use:
DoCmd.OpenForm "NameOfFirstForm",,"[CatalogNumber] =
Forms!NameOfSecondForm!CatalogNumber

PC Datasheet
Providing Customers A Resource For Help With Access, Excel And Word
Applications
(e-mail address removed)
 
Steve said:
David,

If this is a followup question to my first recommendation, in the second
form with the textboxes, if you are displaying the catalog number put the
following code in the click event of that field. If you are not displaying
the catalog number, add it to your form and set its visible property to
False then put the following code in the clck event of one of the other
fields.
DoCmd.OpenForm "NameOfFirstForm",,"[CatalogNumber] = "'" &
Forms!NameOfSecondForm!CatalogNumber & "'"

The above assumes that CatalogNumber is text. If it is numeric, use:
DoCmd.OpenForm "NameOfFirstForm",,"[CatalogNumber] =
Forms!NameOfSecondForm!CatalogNumber

PC Datasheet

--
==>Let's ask it the 'nice' way...
Would you please, please go away Steve ??

This is to inform 'newbees' here about PCD' Steve:
http://home.tiscali.nl/arracom/whoissteve.html
Until now 3700+ pageloads, 2375+ first-time visitors
(these figures are real and rapidly increasing)

Why is this ???
Because Steve is the ONLY person here who continues to advertise in the groups.

It is not relevant whether he advertised in *this* particular post or not...
==> We want him to know that these groups are *not* his private hunting grounds!

For those who don't like too see all these messages:
==> Simply killfile 'StopThisAdvertising'.
Newbees will still see this warning-message.

ArnoR
 
Back
Top