S
Scott
Hello, I have a problem with a database built in Access
2000.
The problem is when I click on a command button for a
specific report the report switches to design view and
then the attempts to print every record in the database!
Converting database to 2002 does not help.
I believe it is this line causing the problem:
DoCmd.OpenReport stDocName, acNormal
Here is the VB code that Access 2002 is returning
erronoeous results:
Private Sub cmdPrintMark_Click()
On Error GoTo Err_cmdPrintMark_Click
Dim stDocName As String
stDocName = "PullCard"
DoCmd.OpenReport stDocName, acNormal
Call parseString(strItems)
If Forms!frmCirSelect.booRevised = True Then
Forms!frmCirSelect!lstFound.Requery
Forms!frmCirSelect!lblFound.Caption = "Records
Found: " & Forms!frmCirSelect.getCount(Forms!
frmCirSelect.strFilter)
End If
Exit_cmdPrintMark_Click:
DoCmd.Close acForm, "frmCardPrint"
DoCmd.Close acReport, "PullCard"
Exit Sub
Err_cmdPrintMark_Click:
MsgBox Err.Description
Resume Exit_cmdPrintMark_Click
End Sub
Keep in mind that this works perfect in Access 2000!
2000.
The problem is when I click on a command button for a
specific report the report switches to design view and
then the attempts to print every record in the database!
Converting database to 2002 does not help.
I believe it is this line causing the problem:
DoCmd.OpenReport stDocName, acNormal
Here is the VB code that Access 2002 is returning
erronoeous results:
Private Sub cmdPrintMark_Click()
On Error GoTo Err_cmdPrintMark_Click
Dim stDocName As String
stDocName = "PullCard"
DoCmd.OpenReport stDocName, acNormal
Call parseString(strItems)
If Forms!frmCirSelect.booRevised = True Then
Forms!frmCirSelect!lstFound.Requery
Forms!frmCirSelect!lblFound.Caption = "Records
Found: " & Forms!frmCirSelect.getCount(Forms!
frmCirSelect.strFilter)
End If
Exit_cmdPrintMark_Click:
DoCmd.Close acForm, "frmCardPrint"
DoCmd.Close acReport, "PullCard"
Exit Sub
Err_cmdPrintMark_Click:
MsgBox Err.Description
Resume Exit_cmdPrintMark_Click
End Sub
Keep in mind that this works perfect in Access 2000!