+ Reply to Thread
Results 1 to 8 of 8

Change Getfolder to a filepath directory.

  1. #1
    Forum Contributor
    Join Date
    01-06-2012
    Location
    London, England
    MS-Off Ver
    2013
    Posts
    165

    Change Getfolder to a filepath directory.

    Hi,

    I am using a code which looks up picture names from a cell value and inserts them into the workbook.

    The code uses a Getfolder command to prompt the user to select the folder the pictures are in.
    My question is can I amend this to always take the pictures from a specific directory without prompting the user?

    Here is the code in question:

    Please Login or Register  to view this content.
    Any help you guys can offer would be much appreciated!
    Thanks,
    Last edited by BPSJACK; 12-17-2015 at 06:11 AM.

  2. #2
    Valued Forum Contributor bulina2k's Avatar
    Join Date
    11-20-2012
    Location
    Urziceni, Ialomita, Romania
    MS-Off Ver
    2019 and 365
    Posts
    861

    Re: Change Getfolder to a filepath directory.

    yes, replace
    Please Login or Register  to view this content.
    with
    Please Login or Register  to view this content.
    .. and don't forget to have fun!
    Bogdan.

    mark SOLVED and Add Reputation if my answer pleases you

  3. #3
    Forum Contributor
    Join Date
    01-06-2012
    Location
    London, England
    MS-Off Ver
    2013
    Posts
    165

    Re: Change Getfolder to a filepath directory.

    Thanks that solved it!

    Whilst I'm here I was wondering whether rather than looking up the whole row I could change it to one cell (eg B5).

    Im guessing it would mean changing something in:
    Please Login or Register  to view this content.
    Can anyone help?
    Thanks,

  4. #4
    Valued Forum Contributor bulina2k's Avatar
    Join Date
    11-20-2012
    Location
    Urziceni, Ialomita, Romania
    MS-Off Ver
    2019 and 365
    Posts
    861

    Re: Change Getfolder to a filepath directory.

    I'm sorry but I don't understand your last question. The code in your last code matches perfectly the code in your first post...

  5. #5
    Forum Contributor
    Join Date
    01-06-2012
    Location
    London, England
    MS-Off Ver
    2013
    Posts
    165

    Re: Change Getfolder to a filepath directory.

    It does.

    But the code in the orginal post looks up pictures for all cells in column B. I was wondering whether it would be possible to change the code so it only looks up pictures from cell B5.

    Apologies if this was unclear.

  6. #6
    Valued Forum Contributor bulina2k's Avatar
    Join Date
    11-20-2012
    Location
    Urziceni, Ialomita, Romania
    MS-Off Ver
    2019 and 365
    Posts
    861

    Re: Change Getfolder to a filepath directory.

    try this way

    Please Login or Register  to view this content.
    if this doesn't work either, pls upload your file or a dummy file.

  7. #7
    Forum Contributor
    Join Date
    01-06-2012
    Location
    London, England
    MS-Off Ver
    2013
    Posts
    165

    Re: Change Getfolder to a filepath directory.

    That's brilliant. Thank you so much!

  8. #8
    Valued Forum Contributor bulina2k's Avatar
    Join Date
    11-20-2012
    Location
    Urziceni, Ialomita, Romania
    MS-Off Ver
    2019 and 365
    Posts
    861

    Re: Change Getfolder to a filepath directory.

    Thank you. Please mark the thread as [SOLVED] . See Thread Tools menu.

+ 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. Change filepath in macro based on textbox in form input
    By Jenkins27 in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 02-27-2015, 09:21 PM
  2. Change filepath in macro based on textbox in form input
    By Jenkins27 in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 02-27-2015, 09:12 PM
  3. Help with Set f = fso.Getfolder
    By stevetothink in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 11-08-2013, 10:01 AM
  4. [SOLVED] GetFolder Method of FileSystemObject Fails On Second Pass
    By goss in forum Excel General
    Replies: 4
    Last Post: 11-14-2012, 01:27 PM
  5. Textbox.text to .getfolder(filename)
    By ozan in forum Excel Programming / VBA / Macros
    Replies: 5
    Last Post: 11-09-2012, 10:37 AM
  6. [SOLVED] Copying files from a selected filepath to a filepath mentioned in a worksheet's cell
    By subbby in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 09-10-2012, 03:59 PM
  7. FilePath Date Change
    By TonyforVBA in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 02-08-2011, 10:57 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