Chimp8471
Registered User.
- Local time
- Today, 04:03
- Joined
- Mar 18, 2003
- Messages
- 353
i have been working on this project all week and now it is almost ready to use i am having problems after saving the file to a previous version..
it was designed in Access 2K i need this in access 97, so i saved it as a prior version of Access and opened it and debugged it and saved the modules, but now when i run it i get a message appear saying,
The action or method requires a query name argument
you tried to open the use openquery action or method, but you left the name argument blank, in th equery name argument, enter a query name.
what is this meaning please ? my code is below
it was designed in Access 2K i need this in access 97, so i saved it as a prior version of Access and opened it and debugged it and saved the modules, but now when i run it i get a message appear saying,
The action or method requires a query name argument
you tried to open the use openquery action or method, but you left the name argument blank, in th equery name argument, enter a query name.
what is this meaning please ? my code is below
Code:
Option Compare Database
Option Explicit
Private Sub DisplaySection_AfterUpdate()
Select Case DisplaySection
Case 1
Me.ByMachine.Visible = True
Me.ByEventcode.Visible = False
Case 2
Me.ByEventcode.Visible = True
Me.ByMachine.Visible = False
End Select
End Sub
Private Sub cmdRunQuery_Click()
On Error GoTo Err_cmdRunQuery_Click
DoCmd.SetWarnings False
DoCmd.OpenQuery ("qEventcodeanalysis")
DoCmd.SetWarnings True
Select Case Me.DisplaySection
Case 1
DoCmd.OpenQuery Me.ByMachine.Column(1), , acReadOnly
Case 2
DoCmd.OpenQuery Me.ByEventcode.Column(1), , acReadOnly
End Select
Exit_cmdRunQuery_Click:
Exit Sub
Err_cmdRunQuery_Click:
MsgBox Err.Description
Resume Exit_cmdRunQuery_Click
End Sub
Private Sub DisplaySection_Enter()
If (Len(cboDaycodeStart & vbNullString) = 0) Or (Len(cboDaycodeEnd & vbNullString) = 0) Or (Len(Line & vbNullString) = 0) Then
If (Len(cboDaycodeStart & vbNullString) = 0) Or (Len(cboDaycodeEnd & vbNullString) = 0) Then
MsgBox "Please enter start and end Daycodes"
If (Len(cboDaycodeStart & vbNullString) = 0) Then
Me.cboDaycodeStart.SetFocus
Exit Sub
ElseIf (Len(cboDaycodeEnd & vbNullString) = 0) Then
Me.cboDaycodeEnd.SetFocus
Exit Sub
End If
End If
If Len(Line & vbNullString) = 0 Then
MsgBox "Please select a line"
Me.Line.SetFocus
End If
End If
End Sub
Private Sub cmdClose_Click()
On Error GoTo Err_cmdClose_Click
DoCmd.Close
Exit_cmdClose_Click:
Exit Sub
Err_cmdClose_Click:
MsgBox Err.Description
Resume Exit_cmdClose_Click
End Sub
Last edited: