Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Opening an instance of Windows Explorer from Access

Status
Not open for further replies.

frankis

Programmer
Sep 21, 2003
14
GB
I'm trying to open Windows Explorer at a folder that relates to the current record.

n Error GoTo StartError
Dim objOutlook As Object

'Create a Microsoft Outlook object.
Set objExplorer= CreateObject("WinExplorer.Application")

Set objExplorer = Nothing

Exit Sub
StartError:
MsgBox "Error: " & Err & " " & Error
Exit Sub

Is it possible to open Explorer like you would Excel etc?

many thanks
 
First off, you create "objOutlook" but you're trying to Set "objExplorer". The name of the object is not important but you have to set the right name.

n Error GoTo StartError
Dim objOutlook As Object

'Create a Microsoft Outlook object.
Set objExplorer= CreateObject("WinExplorer.Application")

Set objExplorer = Nothing

Exit Sub
StartError:
MsgBox "Error: " & Err & " " & Error
Exit Sub
 
open Windows Explorer at a folder
In Access VBA:
FollowHyperlink "\path\to\folder"

Hope This Helps, PH.
Want to get great answers to your Tek-Tips questions? Have a look at FAQ219-2884 or FAQ181-2886
 
Or

Code:
Dim RetVal
RetVal = Shell("C:\WINDOWS\explorer.EXE C:\SomeFolder", 1)
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top