data relation between no related forms

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

Guest

i have 3 form without relationship. 1. form including other 2 form. 2 form
inside first form have datasheet apperance. i wanna that if i select in 1.
datasheet a record then in 2. datasheet will show me selected record's
details. thaks for your helps.
 
Esmaeild,

This means there is a field in both forms that relates the data from one
to another. I will assume this field is ID.

On the main form, put an unbound textbox, which will reference the value
of the ID field in the current record of the 1st subform. This textbox
cn be hidden (i.e. Visible property set to No) if you like. Let's say
you give this textbox the name of IDRef. Ok, then in the Properties of
the 2nd subform, set the LinkChildFields property to ID and the
LinkMasterFields property to IDRef.
 
i have 3 form without relationship.

Forms don't have relationships. A Form is ONLY A WINDOW - a tool to
manage data stored in Tables. Tables can have relationships.
1. form including other 2 form. 2 form
inside first form have datasheet apperance. i wanna that if i select in 1.
datasheet a record then in 2. datasheet will show me selected record's
details. thaks for your helps.

Please explain the Tables and their relationships. It sounds like a
Form with a Subform will work, but since I don't understand your data
it's hard to say.

John W. Vinson[MVP]
 
Esmaeild,

I am sorry, on reviewing my post, I see I forgot to include some key
information! You would set the Control Source of the IDRef textbox to
the equivalent of this...
=[NameOfFirstSubform]![ID]
....or, as some would have it...
=[NameOfFirstSubform].[Form]![ID]
 
hello,

i have 2 table. for example stockTBL and stockDetailsTBL
that tables related on stockTBL's LOGICALREF (PK) with stockDetailsTBL's
STOCKREF (FK)

i created an empty form and individually generated 2 forms stockTBL and
StockDetailsTBL.

after that i put this 2 forms using drag-drop on empty form and i set 2 forms
apperance by datasheet.

i put a textfield on main form. i coded textfield's change event for filter
stockTBL.

i wanna during that filtering prosses, stockDetailsTBL show me stockTBL's
details.

i resolved problem but there is a new problem. i didn't find where will am i
write
that code for filter only tied record with parent table:

dd = Form_browser_alt.SelectedRow(Form_browser_alt, "LOGICALREF")
Form_frmSayim.Filter = "STOCKREF = '" & Str(dd) & "'"

i wrote that code every where but i didn't find anywhere whithout that error.
which event is appropriate for that.

RunTime Error '2001'
You canceled the previous operation.

i think that this error said that me "you didn finish previous prosses
(textbox's change event) "

how can i do?

thanks for all.
 
thank you Steve. LinkChild and LinkMaster Properties are exactly what i was
looking for. thanks for all your help.
 
Back
Top