field on subform link with form

totolkhan

Registered User.
Local time
Today, 08:06
Joined
May 23, 2005
Messages
30
hi

i have a form just like customer orders in Northwind
with 2 subforms
Subform1 is showing orders number and i want to add something on that

subform 2 is products that ordered !

i want to add something on subform1 that if i Dbl Click on orderID field
it will sho for example another Form "orders"
i'm trying this code but i can't do it


Private Sub OrderID_DblClick(Cancel As Integer)
Dim stDocName As String
Dim stLinkCriteria As String

stDocName = "orders"

stLinkCriteria = "[OrderID]=" & "'" & Me![OrderID] & "'"
DoCmd.OpenForm stDocName, , , stLinkCriteria

Exit Sub
End Sub


would u please help me
 
Try:
stLinkCriteria = "[OrderID]=" & Me![OrderID]

HTH,
Shane
 

Users who are viewing this thread

Back
Top Bottom