I have set up some code that will automatically generate an email using Groupwise. The problem is, I need to pass the user defined parameter in the DoCmd part of the VB.
Here's what I've got:
Private Sub cmdGO_Click()
On Local Error GoTo Some_Err
Dim MyDB As Database, RS As Recordset
Dim strBody As String, lngCount As Long, lngRSCount As Long
Dim strTO As String
Dim strSubject As String
Dim intMessageID As Integer
'DoCmd.RunCommand acCmdSaveRecord
Set MyDB = DBEngine.Workspaces(0).Databases(0)
Me!txtProgress = Null
Set RS = MyDB.OpenRecordset _
("qryLateResults"
At this point, it kicks to my error handler with the message "Error(3061) Too few parameters. Expected 1"
How can I allow the user to input the parameter and pass it to the query so that it will run the query properly (I don't wish to send out my entire database of events....)
Thanks,
MTB Chick
Here's what I've got:
Private Sub cmdGO_Click()
On Local Error GoTo Some_Err
Dim MyDB As Database, RS As Recordset
Dim strBody As String, lngCount As Long, lngRSCount As Long
Dim strTO As String
Dim strSubject As String
Dim intMessageID As Integer
'DoCmd.RunCommand acCmdSaveRecord
Set MyDB = DBEngine.Workspaces(0).Databases(0)
Me!txtProgress = Null
Set RS = MyDB.OpenRecordset _
("qryLateResults"
At this point, it kicks to my error handler with the message "Error(3061) Too few parameters. Expected 1"
How can I allow the user to input the parameter and pass it to the query so that it will run the query properly (I don't wish to send out my entire database of events....)
Thanks,
MTB Chick