G
Guest
HI
I am trying to pass an argument from one form to another (from a service
mainform to a staff data entry form). The argument is called "serviceN",
which takes its value from a combo box on a mainform frmServices. I want to
pass ServiceN to a popup form FrmStaff_Entry.
I am using the following code activated by a button on the mainform:
Private Sub Namex_DblClick(Cancel As Integer)
DoCmd.OpenForm "frmStaff_Entry", , , "Name = " & Chr(34) & Me.Namex &
Chr(34), , , "ServiceN"
End Sub
Ok. so this uses openargs to pass the argument ServiceN over to the
frmService_Entry as it opens.... so far so good
what I need is to now have the value carried by the ServiceN argument
display on the frmServiceEntry. I wrote this little sub on frmStaff_Entry to
see where i am up to at this point:
Private Sub Command28_Click()
MsgBox OpenArgs
End Sub
....and it displays the NAME of the argument (ServiceN), and not the value it
holds (ie a sevice name from the combo on the original form).
How do i 'translate' a passed argument back into the viewable value it
contains? Ultimately this passed value informs access which service the staff
member is attatched to....
I have followed various previously posted answers to similar questions to
mine, but to no avail.
thanks
I am trying to pass an argument from one form to another (from a service
mainform to a staff data entry form). The argument is called "serviceN",
which takes its value from a combo box on a mainform frmServices. I want to
pass ServiceN to a popup form FrmStaff_Entry.
I am using the following code activated by a button on the mainform:
Private Sub Namex_DblClick(Cancel As Integer)
DoCmd.OpenForm "frmStaff_Entry", , , "Name = " & Chr(34) & Me.Namex &
Chr(34), , , "ServiceN"
End Sub
Ok. so this uses openargs to pass the argument ServiceN over to the
frmService_Entry as it opens.... so far so good
what I need is to now have the value carried by the ServiceN argument
display on the frmServiceEntry. I wrote this little sub on frmStaff_Entry to
see where i am up to at this point:
Private Sub Command28_Click()
MsgBox OpenArgs
End Sub
....and it displays the NAME of the argument (ServiceN), and not the value it
holds (ie a sevice name from the combo on the original form).
How do i 'translate' a passed argument back into the viewable value it
contains? Ultimately this passed value informs access which service the staff
member is attatched to....
I have followed various previously posted answers to similar questions to
mine, but to no avail.
thanks