Your code works like a charm with my orders field.
I don't understand anything of VB (except what I try to learn from the VB
help) but I also tried it with my products table but it doesn't work. I
think
it is because my products reference field (and primary key) "Reference"
is of
string type and manually inputed. I tried to change your code in the
,,,'where' statement of the open form command but it only brings up an
empty
form and several code errors
Can you help me setting it for this
string
type filter (by the way "Me!" refers to a filter, am I right?)
Thank you very much Gary.
Gary Miller said:
Jose,
There is a DoubleClick event for textboxes (and many
controls). Put your code to open the form there by clicking
on the event builder button and choosing Code. You will have
to modify this for your control and form names...
docmd.OpenForm "YourFormName",,,"[OrderID] = " & Me!OrderID
--
Gary Miller
Sisters, OR
message
Greets.
I have a Form listing all my orders (number type) as the
primary key for an
orders table. I want to double click one of the orders
shown (double click
the text box) and open other form that contains all
details FROM THAT ORDER
alone.
Thanks for the help.