+ Reply to Thread
Results 1 to 3 of 3

Setting a path to a folder

  1. #1
    Boots
    Guest

    Setting a path to a folder

    I have created a macro that checks if a folder is present and if it isn't it
    creates it. The macro continues to save the active workbook. The creation
    of the folder works great but the the workbook is being saved in mydocuments
    rather than the folder created. How do I code to save it in the folder
    created?
    I'm pretty sure it just involves setting the path but i'm not sure on the
    syntax

    thanks in advance

  2. #2
    Boots
    Guest

    RE: Setting a path to a folder

    I've solved it using chdir

    "Boots" wrote:

    > I have created a macro that checks if a folder is present and if it isn't it
    > creates it. The macro continues to save the active workbook. The creation
    > of the folder works great but the the workbook is being saved in mydocuments
    > rather than the folder created. How do I code to save it in the folder
    > created?
    > I'm pretty sure it just involves setting the path but i'm not sure on the
    > syntax
    >
    > thanks in advance


  3. #3
    Bob Phillips
    Guest

    Re: Setting a path to a folder

    Something like

    Activeworkbook.SaveAs myPath & "\" & myFilename

    where myPath is the path you checked/created.

    --
    HTH

    Bob Phillips

    (replace somewhere in email address with gmail if mailing direct)

    "Boots" <[email protected]> wrote in message
    news:[email protected]...
    > I have created a macro that checks if a folder is present and if it isn't

    it
    > creates it. The macro continues to save the active workbook. The

    creation
    > of the folder works great but the the workbook is being saved in

    mydocuments
    > rather than the folder created. How do I code to save it in the folder
    > created?
    > I'm pretty sure it just involves setting the path but i'm not sure on the
    > syntax
    >
    > thanks in advance




+ Reply to Thread

Thread Information

Users Browsing this Thread

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

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