Skip Bisconer
Who Me?
- Local time
- Today, 06:31
- Joined
- Jan 22, 2008
- Messages
- 285
I am trying to open a view of some linked Excel spreadsheets with an option box using the select case statement. When I try to use the below code for the case statement I get the error "Wrong number of arguments or invalid property assignment." on the the docmd.OpenForm code. This code works fine with the OpenForm method on another option box.
Questions are there different arguments for tables? Or can you view linked tables through code?
Questions are there different arguments for tables? Or can you view linked tables through code?
Code:
Private Sub cmdViewSpreadsheet_Click()
Dim stDocName As String
Select Case Frame10
Case 1
stDocName = "CurrentChargesBisconer"
Me.Visible = False
DoCmd.OpenTable stDocName, acNormal, , , , acDialog
DoCmd.Restore
Me.Visible = True
[COLOR=seagreen]'Case 2 - 12 follow this statement[/COLOR]
End Sub