TigerGyrlAlly
New Member
- Joined
- Jun 11, 2003
- Messages
- 18
I have a button on a form and I would like for a user to be able to press the button and close the form while opening a table. I am using the OpenTable method of the DoCmd object and including all arguments but it still doesn't seem to work...does anyone see what i'm missing?
The error message that I get is this: Compile Error: Expected: =
This is my code and the part in red is where i'm getting my error
Private Sub ActButton_Click()
On Error GoTo Err_ActButton_Click
DoCmd.Close color=yellow]DoCmd.OpenTable(Activity, acViewNormal , acReadOnly)
Exit_ActButton_Click:
Exit Sub
Err_ActButton_Click:
MsgBox Err.Description
Resume Exit_ActButton_Click
End Sub
The error message that I get is this: Compile Error: Expected: =
This is my code and the part in red is where i'm getting my error
Private Sub ActButton_Click()
On Error GoTo Err_ActButton_Click
DoCmd.Close color=yellow]DoCmd.OpenTable(Activity, acViewNormal , acReadOnly)
Exit_ActButton_Click:
Exit Sub
Err_ActButton_Click:
MsgBox Err.Description
Resume Exit_ActButton_Click
End Sub