RichardWebster
IS-IT--Management
I am a lawyer and I have a Access 2000 database which stores information about client's matters and is used to produce Word docs from it. On my main Matters Form which gives the basic details of a particular matter there is a button which calls a procedure to open the Word Open Docs dialogue as follows:
Sub OpenDocsForMatter()
Dim oApp As Word.Application
On Error Resume Next
Set oApp = GetObject(, "Word.Application")
If oApp Is Nothing Then
Set oApp = CreateObject("Word.Application")
End If
oApp.Activate
oApp.Visible = True
'goes to the directory with a name related to the currently
'open record on the Matters Form - MWP is a function that
'points to that
oApp.ChangeFileOpenDirectory MWP()
oApp.Dialogs(wdDialogFileOpen).Show
End Sub
I would like to be able to open the same folder in Windows Explorer so I am not limited to opening the documents in Word as some may be PDFs or TIFs Does anyone know how it can be done in VBA for Office 2000?
Sub OpenDocsForMatter()
Dim oApp As Word.Application
On Error Resume Next
Set oApp = GetObject(, "Word.Application")
If oApp Is Nothing Then
Set oApp = CreateObject("Word.Application")
End If
oApp.Activate
oApp.Visible = True
'goes to the directory with a name related to the currently
'open record on the Matters Form - MWP is a function that
'points to that
oApp.ChangeFileOpenDirectory MWP()
oApp.Dialogs(wdDialogFileOpen).Show
End Sub
I would like to be able to open the same folder in Windows Explorer so I am not limited to opening the documents in Word as some may be PDFs or TIFs Does anyone know how it can be done in VBA for Office 2000?