View Single Post
 
Old 05-25-2021, 08:43 AM
SamDsouza SamDsouza is offline Windows 10 Office 2013
Advanced Beginner
 
Join Date: Aug 2019
Posts: 71
SamDsouza is on a distinguished road
Default

Andrew

Really No fun with below code as per your suggestion.
As i tried Filepicker for First time. Pressing OK in Msg box
Msgbox Disappears and File does not open.
Code:
Public Sub DirPathNamesWithFilePicker()

Set xFd = Application.FileDialog(msoFileDialogFilePicker)

       With xFd
       .Title = "Select the Folder..."
             .Filters.Clear
             .Filters.Add "PDF Files", "*.PDF", 1
              If .Show = -1 Then
              For Each xFdItem In .SelectedItems
                  MsgBox "Path Name : " & xFdItem
                 Next xFdItem
              Else
              
              End If
        End With

Set xFd = Nothing
End Sub
Quote:
This way you just return the chosen PDF to the userform (or avoid the userform completely if that was all it was for)
I should not have posted the thread if i had to select the file and open it.

As a common user or Data Entry operator for eg not Knowing what PDF is
How would they perceive a PDF Image or cover with images with Stylish fonts BUT not Editable. If i were in their Place I would perceive as an Decorative Image with Text in a Rectangular Frame.

By the way
Bit scared to use the
Imagebox1.Picture = LoadPicture(xFditem)
and ActiveDocument.Pictures.insert(xFdItem)

I dont have anythinng of Adobe installed. with MS-Edge quite happy to view PDF at least
SamD
Reply With Quote