+ Reply to Thread
Results 1 to 5 of 5

GetFile - Set default folder using network path

  1. #1
    Registered User
    Join Date
    11-20-2010
    Location
    Delaware, USA
    MS-Off Ver
    Excel 2003
    Posts
    73

    GetFile - Set default folder using network path

    Hi All,

    I'm trying to code a macro that prompts the user to select a file to open, but I'd like it to default to a certain folder and network path.

    for instance,

    ChDrive "Z"
    ChDir "Z:\New Folder"

    Is an example of what I want, but not all users have the network mapped as Z:\, so I'd ike to use the path:

    \\thisserver.example.testing.com\something\somewhere\here\

    Can this be done?

    Thanks!
    Last edited by Pergo; 03-26-2015 at 11:17 AM.

  2. #2
    Registered User
    Join Date
    11-20-2010
    Location
    Delaware, USA
    MS-Off Ver
    Excel 2003
    Posts
    73

    Re: GetFile - Set default folder using network path

    Apologies for the bump-- any update on this?

    Thanks!

  3. #3
    Forum Expert shg's Avatar
    Join Date
    06-20-2007
    Location
    The Great State of Texas
    MS-Off Ver
    2010, 2019
    Posts
    40,689

    Re: GetFile - Set default folder using network path

    I believe ChDrive and ChDir only work for local and mapped drives. See https://social.technet.microsoft.com...ba?forum=excel
    Entia non sunt multiplicanda sine necessitate

  4. #4
    Registered User
    Join Date
    11-20-2010
    Location
    Delaware, USA
    MS-Off Ver
    Excel 2003
    Posts
    73

    Re: GetFile - Set default folder using network path

    This works.

    Thank you!

  5. #5
    Forum Expert shg's Avatar
    Join Date
    06-20-2007
    Location
    The Great State of Texas
    MS-Off Ver
    2010, 2019
    Posts
    40,689

    Re: GetFile - Set default folder using network path

    You're welcome.

+ 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. Code to list the folder path and sub folder path of a specific file
    By kalai1587 in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 11-13-2013, 03:51 AM
  2. Excel VBA get Network path from local path
    By katto01 in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 04-26-2013, 11:31 AM
  3. [SOLVED] Save As Dialog Box - Default Path and File Name, User Selects Sub Folder from Default Path
    By christenprochaska in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 12-12-2012, 05:17 PM
  4. Can not change default folder to network resource
    By side_ in forum Excel Programming / VBA / Macros
    Replies: 6
    Last Post: 05-11-2006, 10:09 AM
  5. Help with path for shared folder on network
    By rrmando in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 01-12-2005, 09:54 PM

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