+ Reply to Thread
Results 1 to 4 of 4

Search for a file using a macro?

  1. #1
    Registered User
    Join Date
    05-04-2012
    Location
    Tacoma, WA
    MS-Off Ver
    Excel 2007
    Posts
    12

    Search for a file using a macro?

    I have over 4000 files for customer equipment. Those files contain pictures and closed work orders for the equipment. I have set up a master sheet and pulled specific information about the customers equipment but need to have a quick way for others to go directly to the folder. Is there a way that I can create a search shortcut for a specific folder located on my x: drive based on the information that is entered into the master sheet in cell B2?

    Any input is appreciated.

  2. #2
    Forum Contributor
    Join Date
    05-04-2012
    Location
    Stamford,Connecticut,USA
    MS-Off Ver
    Excel 2003
    Posts
    105

    Re: Search for a file using a macro?

    Yes, first select Cell B2, then from the insert menu, select Hyperlink, make sure you have selected the Existing File icon on the right, then type in a text to display(Something like shortcut to x - See picture attached), in the lookin box select your drive X; then make sure your address is X:\
    After hitting OK the Excel file will show an underlined blue text that is your shortcut to X:
    Picture1.jpg

    If this was helpful, please show your gratitude by clicking on the Star icon on the left bottom side of the posting, and don't forget to mark your question as Answered.

  3. #3
    Registered User
    Join Date
    05-04-2012
    Location
    Tacoma, WA
    MS-Off Ver
    Excel 2007
    Posts
    12

    Re: Search for a file using a macro?

    Thanks for the reply, is there any way to take it a step further and have it search for the appropriate file on drive X and return the search results?

  4. #4
    Forum Guru Kyle123's Avatar
    Join Date
    03-10-2010
    Location
    Leeds
    MS-Off Ver
    2016 Win10
    Posts
    7,176

    Re: Search for a file using a macro?

    I'm not sure there's a really fast way of doing it, but try the attached. The more of the file path you can provide (and the fewer sub-directories) the faster the code will be.

    I've had to attach, the forum won't let me post this.
    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)

Tags for this Thread

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