Report asking to enter a parameter value (1 Viewer)

Tina49

Registered User.
Local time
Yesterday, 23:19
Joined
Sep 29, 2011
Messages
34
I am running a report but it is asking me to enter a parameter value. Can anyone tell me what is going on? When I go to debug it takes me to the bolded line. That is what my report is called. Thanks in advance to any help you can give.

[FONT=&quot]Private Sub Command12_Click()
Dim res As Recordset
Dim Chz As Integer
Chz=Forms!Edreports!Frame7
If Check63 Then
Chz=Chz*10
End If
Select Case Chz
Case 1 'Attendance Report
IfIsNull(Combo31) Then
DoCmd.OpenReport "EdRep4a", acPreview 'for Class
Else
DoCmd.OpenReport "EdRep4b", acPreview 'for Employee
End If
Case 2 'Non Attend Reminder List
DoCmd.OpenReport "EdRep6", acPreview
Case 3 'Non Attend Reminder List
DoCmd.OpenReport "EdRep5", acPreview
Case 4 'Annual Report
DoCmd.OpenReport "EdRep0", acPreview
Case 5 'Print Names
DoCmd.OpenReport "EdRep7", acPreview
Case 6 'Print Appraisal by date
DoCmd.OpenReport "EdRep6", acPreview
Case 10 'Class by Department-Break by Department
DoCmd.OpenReport "EdRep4", acPreview 'for Class
Case 20 'Non Attendance Reminder List- Break by department
DoCmd.OpenReport "EdRep4b", acPreview
End Select
End Sub[/FONT]
 

Galaxiom

Super Moderator
Staff member
Local time
Today, 16:19
Joined
Jan 20, 2009
Messages
12,852
Can you open the report directly?

Asking for parameters is usually due to a mispelled field or tablename. The name it asks for should give you some clue to where it could be. Check the RecordSource of the report, RowSources for its combos or listboxes.

Have you changed the name of any fields or tables? If Name AutoCorrect is off then you would need to update the references in other places. Even when it is on, NAC does not find all references to changed names.

It may be a corruption issue too especially if you changed names with NAC on.
 

Tina49

Registered User.
Local time
Yesterday, 23:19
Joined
Sep 29, 2011
Messages
34
I can open the report directly. Where would I find Name Auto Correct?
 

Galaxiom

Super Moderator
Staff member
Local time
Today, 16:19
Joined
Jan 20, 2009
Messages
12,852
If the report opens directly then it should also open with code.

What parameter does it ask for?
 

Tina49

Registered User.
Local time
Yesterday, 23:19
Joined
Sep 29, 2011
Messages
34
It asks me for Department.Employee number
 

Tina49

Registered User.
Local time
Yesterday, 23:19
Joined
Sep 29, 2011
Messages
34
When I debug it takes me to DoCmd.OpenReport "EdRep4a", acPreview 'for class
 

DirkVanGiel

New member
Local time
Today, 08:19
Joined
Sep 17, 2012
Messages
2
I also have a problem with an unwanted parameter showing up when I run a report.
I have removed a field from the detail section of a report after having it removed from the pertaining Record Source Query. However when I run the report Access shows a popup window asking to enter a value for the removed field. Luckely it does not affect the results of the report but still I do not like this popup window to show up.
Any ideas ?
 
Last edited:

Users who are viewing this thread

Top Bottom