A
Aref Mikati
In the following code, the Filters.Add method is, from time to time, raising
err 438.
Any suggestions?
Set fd = Application.FileDialog(msoFileDialogOpen)
With fd
.AllowMultiSelect = False
.ButtonName = "Open"
.Title = gstrDefaultTitle & " - Project: " & Mid(strInitialFileName,
4, 3)
.Filters.Clear
.Filters.Add "All Files", "*.*", 1
.Filters.Add "Images", "*.gif; *.jpg; *.jpeg; *.tif; *.pdf", 2
.FilterIndex = 2
.InitialView = msoFileDialogViewDetails
.InitialFileName = strInitialFileName
If .Show = -1 Then
Application.FollowHyperlink .SelectedItems(1)
End If
End With
Set fd = Nothing ' Dim dummy As Boolean
err 438.
Any suggestions?
Set fd = Application.FileDialog(msoFileDialogOpen)
With fd
.AllowMultiSelect = False
.ButtonName = "Open"
.Title = gstrDefaultTitle & " - Project: " & Mid(strInitialFileName,
4, 3)
.Filters.Clear
.Filters.Add "All Files", "*.*", 1
.Filters.Add "Images", "*.gif; *.jpg; *.jpeg; *.tif; *.pdf", 2
.FilterIndex = 2
.InitialView = msoFileDialogViewDetails
.InitialFileName = strInitialFileName
If .Show = -1 Then
Application.FollowHyperlink .SelectedItems(1)
End If
End With
Set fd = Nothing ' Dim dummy As Boolean