+ Reply to Thread
Results 1 to 4 of 4

Populate Listbox with PDF Files and Open File

Hybrid View

  1. #1
    Registered User
    Join Date
    10-20-2016
    Location
    Singapore
    MS-Off Ver
    Microsoft Office Standard 2016
    Posts
    5

    Populate Listbox with PDF Files and Open File

    I would like to know
    how to populate listbox with PDF files from a folder filled with PDF files?
    And how do I open a PDF file on the populated listbox with a commandbutton?

  2. #2
    Forum Guru bakerman2's Avatar
    Join Date
    10-03-2012
    Location
    Antwerp, Belgium
    MS-Off Ver
    MSO Home and Business 2024
    Posts
    7,335

    Re: Populate Listbox with PDF Files and Open File

    Is the ListBox and CommandButton on a worksheet or in a Userform?
    Avoid using Select, Selection and Activate in your code. Use With ... End With instead.
    You can show your appreciation for those that have helped you by clicking the * at the bottom left of any of their posts.

  3. #3
    Registered User
    Join Date
    10-20-2016
    Location
    Singapore
    MS-Off Ver
    Microsoft Office Standard 2016
    Posts
    5
    Quote Originally Posted by bakerman2 View Post
    Is the ListBox and CommandButton on a worksheet or in a Userform?
    Hi my friend. It's in the userform.

  4. #4
    Forum Guru bakerman2's Avatar
    Join Date
    10-03-2012
    Location
    Antwerp, Belgium
    MS-Off Ver
    MSO Home and Business 2024
    Posts
    7,335

    Re: Populate Listbox with PDF Files and Open File

    Try example file.
    First adapt path in userform code. Then by clicking a name in the ListBox opens pdf-file.
    Attached Files Attached Files

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. Listbox of open files with a common worksheet name
    By cboud in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 01-21-2016, 05:58 PM
  2. Populate listbox with file names by date modified??
    By Nu2Java in forum Excel Programming / VBA / Macros
    Replies: 6
    Last Post: 06-09-2014, 11:23 PM
  3. Listbox open files pdf
    By savyback in forum Excel Programming / VBA / Macros
    Replies: 15
    Last Post: 08-10-2013, 08:46 AM
  4. [SOLVED] populate listbox from another excel file with country column
    By plk in forum Excel Programming / VBA / Macros
    Replies: 11
    Last Post: 04-12-2012, 04:24 PM
  5. Replies: 3
    Last Post: 08-21-2011, 07:55 PM
  6. Replies: 0
    Last Post: 08-21-2011, 07:38 AM
  7. populate all file names from folder to listbox
    By dan2010 in forum Excel Programming / VBA / Macros
    Replies: 16
    Last Post: 08-21-2011, 06:34 AM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1