B
BRC
Hi all
I am trying to open a form to a specific record based on dbl clicking
a record on the sub form of another form. Here is the situation.
Form1 (SelReceditFrm ) is open with a date field where user enters
date
after user selects date all "events" for that date show up in subform.
When user dblclicks on an event listed in the subform I want the event
form("eventtfrm" to upen to that record in the edit mode.
when the user dbl clicks on the event I set a message box to display
the "eventKey" which is the event i want to edit.
this is the code
Private Sub event_DblClick(Cancel As Integer)
dim evk as interger
'evnetkey is an auto number field
evk = Me.EventKey
MsgBox (evk)
'DoCmd.OpenForm "eventFrm", , "[eventkey]='" & evk& "' "
'DoCmd.OpenForm "eventFrm", acNormal, , EventKey = evk, acFormEdit
'DoCmd.OpenForm "eventFrm", acNormal, filt, EventKey = filt,
acFormedit,,,)
End Sub
my problem may have something to do with punctuation but I can't find
a good explanation of how to punctuate.
I am trying to open a form to a specific record based on dbl clicking
a record on the sub form of another form. Here is the situation.
Form1 (SelReceditFrm ) is open with a date field where user enters
date
after user selects date all "events" for that date show up in subform.
When user dblclicks on an event listed in the subform I want the event
form("eventtfrm" to upen to that record in the edit mode.
when the user dbl clicks on the event I set a message box to display
the "eventKey" which is the event i want to edit.
this is the code
Private Sub event_DblClick(Cancel As Integer)
dim evk as interger
'evnetkey is an auto number field
evk = Me.EventKey
MsgBox (evk)
'DoCmd.OpenForm "eventFrm", , "[eventkey]='" & evk& "' "
'DoCmd.OpenForm "eventFrm", acNormal, , EventKey = evk, acFormEdit
'DoCmd.OpenForm "eventFrm", acNormal, filt, EventKey = filt,
acFormedit,,,)
End Sub
my problem may have something to do with punctuation but I can't find
a good explanation of how to punctuate.