+ Reply to Thread
Results 1 to 5 of 5

Path for File Saving Defined by USER

  1. #1
    Registered User
    Join Date
    06-13-2007
    Posts
    58

    Path for File Saving Defined by USER

    Hi All,

    I have written the following code:

    Please Login or Register  to view this content.

    This code save the new file in a pre-defined path and gives a particular name only...

    I want whenever user runs this macro.....they should get a Saving Option (As it is in Windows new file Save Option).


    Is it possible??/
    Last edited by VBA Noob; 09-20-2007 at 02:48 PM.

  2. #2
    Forum Expert mikerickson's Avatar
    Join Date
    03-30-2007
    Location
    Davis CA
    MS-Off Ver
    Excel 2011
    Posts
    6,229
    Have you looked at Application.SaveAsFileName. This routine shows how it goes.
    Please Login or Register  to view this content.
    Note that it does not save the file. The built in SaveAs dialog does that.

    Please Login or Register  to view this content.
    will return didSave=True if the file is saved, didSave=False if Cancel is pressed.

    There is also a Save Copy As dialog like the above, xlDialogSaveCopyAs.

  3. #3
    Registered User
    Join Date
    06-13-2007
    Posts
    58
    Hey Thanks Mike,

    But to be frank... I am not an VBA champ.... I tried to juggle the codes you provided... but cudnt get what i want...

    As you can see in my code... that I want create a .txt file out of the macro..

    Thats what i can not do now...

    Help me ...

  4. #4
    Forum Expert mikerickson's Avatar
    Join Date
    03-30-2007
    Location
    Davis CA
    MS-Off Ver
    Excel 2011
    Posts
    6,229
    I've altered your code to include the user choice.
    Please Login or Register  to view this content.

  5. #5
    Registered User
    Join Date
    06-13-2007
    Posts
    58
    Thanks A lot ...

+ 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