Hi !
i'm falling in headache status.
i have 3 forms linking together by the sub/main form way.
1st form named fcontract: biggest
2nd form named fdetailcontract
3rd named fshipmentcontract: is smallest.
1st & 2nd linked by ContNo.
2nd & 3rd linked by a togglelink button through fields: ContNo and ProNo.
i want to fill ContNo and ProNo of 3rd by the value of these record of 2nd
that i just type in 2nd. i mean when i press the togglelink to open the
3rd for adding new record, ContNo and ProNo are filled automatically by
the value of ContNo and ProNo of 2nd after each new record.
i made them by wizard and i want to revise the code for my goal. but it is
false.
how can i solve them?
Pls help !
thanks in advance
here are the code create by wizard
Sub ToggleLink_Click()
On Error GoTo ToggleLink_Click_Err
If ChildFormIsOpen() Then
CloseChildForm
Else
OpenChildForm
FilterChildForm
End If
ToggleLink_Click_Exit:
Exit Sub
ToggleLink_Click_Err:
MsgBox Error$
Resume ToggleLink_Click_Exit
End Sub
Private Sub FilterChildForm()
If Me.NewRecord Then
Forms![FshipmentContract].DataEntry = True
Else
Forms![Fshipmentcontract].Filter = "[ContNo] = " & """" &
Me.[ContNo] & """" & " AND [ProNo] = " & """" & Me.[ProNo] & """"
Forms![FGIAOHANG].FilterOn = True
End If