I'm trying to open another Access database with wrkgroup parameters using the Shell function. I get a "file not found" error when trying to run the function. Here's what I have:
I can paste the above string in the target location of a desktop shortcut and it opens just fine. I'm sure it has something to do with the spaces but it seems I tried everything but I can't get it to work. Any help out there?
Thanks in advance.
Code:
Dim varSitewide As Variant
Dim curUsr As String
curUsr = CurrentUser()
Const q As String * 1 = """"
MsgBox "Opening SEAMS..."
varSitewide = "C:\Program Files\Office 2003\OFFICE11\MSACCESS.EXE" & "C:\Documents and Settings\e3utbl\Desktop\Devl Databases\SCC_Dashboard\CSS_APPS\SEAMS\SEAMS.mdb" & " /wrkgrp" & "C:\Documents and Settings\e3utbl\Desktop\Devl Databases\SCC_Dashboard\CSSGrp.mdw" & " /user " & curUsr
RetVal = Shell(varSitewide, 1)
I can paste the above string in the target location of a desktop shortcut and it opens just fine. I'm sure it has something to do with the spaces but it seems I tried everything but I can't get it to work. Any help out there?
Thanks in advance.