F
Frank Martin
I want to open a report RptCustPricelist to display the specific customer
showing on the FrmPriceList.
I am using the following code:
***
Private Sub Command48_Click()
On Error GoTo Err_Command48_Click
Dim stDocName As String
Dim stLinkCriteria As String
stDocName = "RptCustPricelist"
stLinkCriteria = "[AddressesID]=" & "'" & Me![AddressesID] & "'"
DoCmd.OpenReport stDocName, acPreview, , stLinkCriteria
DoCmd.RunCommand acCmdZoom75
Exit_Command48_Click:
Exit Sub
Err_Command48_Click:
MsgBox Err.Description
Resume Exit_Command48_Click
End Sub
***
(AddressesID is an autonumber)
The error message is:
"Runtime error 3464
Datatype mismatch in criteria expression".
I just can't see where this is. Can someone help?
Frank
showing on the FrmPriceList.
I am using the following code:
***
Private Sub Command48_Click()
On Error GoTo Err_Command48_Click
Dim stDocName As String
Dim stLinkCriteria As String
stDocName = "RptCustPricelist"
stLinkCriteria = "[AddressesID]=" & "'" & Me![AddressesID] & "'"
DoCmd.OpenReport stDocName, acPreview, , stLinkCriteria
DoCmd.RunCommand acCmdZoom75
Exit_Command48_Click:
Exit Sub
Err_Command48_Click:
MsgBox Err.Description
Resume Exit_Command48_Click
End Sub
***
(AddressesID is an autonumber)
The error message is:
"Runtime error 3464
Datatype mismatch in criteria expression".
I just can't see where this is. Can someone help?
Frank