G
Guest
I created a parameter query in the form of a drop down box that, once an
option is selected, should display a form with a number of fields pre-filled
from a record chosen by the drop-down selection.
The drop down has a command button with the following code in the Onclick
event:
Private Sub cmdCreateReport_Click()
If IsNull(Me.cboPendingUIRLookUp) Or False Then
MsgBox "Please select a UIR from the drop down list!", vbInformation,
"No Selection"
Me.cboPendingUIRLookUp.SetFocus
Else
DoCmd.OpenForm "frmUIRFollowUp"
DoCmd.Close acForm, "frmOpenUIRLookUp"
End If
End Sub
As it now stands when I click the button I get the form but none of the
selected data is filled in. The fields are blank.
The only thing I can think to do is upload the database and see if there's
anyone willing to download it and take a look. So I've attached a link here...
http://www.box.net/public/static/flkxlzav6f.rar
....where those willing to help are welcome to download it in .rar format.
The form that with the initial drop down box is called frmOpenUIRLookUp (UIR
= Unusual Incident Report, by the way). The form that the drop down is
supposed to feed into is frmOpenUIRLookUp and the query that is supposed to
support that form is qryUIRFollowUpData.
Many, many thanks for the help,
David
option is selected, should display a form with a number of fields pre-filled
from a record chosen by the drop-down selection.
The drop down has a command button with the following code in the Onclick
event:
Private Sub cmdCreateReport_Click()
If IsNull(Me.cboPendingUIRLookUp) Or False Then
MsgBox "Please select a UIR from the drop down list!", vbInformation,
"No Selection"
Me.cboPendingUIRLookUp.SetFocus
Else
DoCmd.OpenForm "frmUIRFollowUp"
DoCmd.Close acForm, "frmOpenUIRLookUp"
End If
End Sub
As it now stands when I click the button I get the form but none of the
selected data is filled in. The fields are blank.
The only thing I can think to do is upload the database and see if there's
anyone willing to download it and take a look. So I've attached a link here...
http://www.box.net/public/static/flkxlzav6f.rar
....where those willing to help are welcome to download it in .rar format.
The form that with the initial drop down box is called frmOpenUIRLookUp (UIR
= Unusual Incident Report, by the way). The form that the drop down is
supposed to feed into is frmOpenUIRLookUp and the query that is supposed to
support that form is qryUIRFollowUpData.
Many, many thanks for the help,
David