+ Reply to Thread
Results 1 to 7 of 7

Run-time error 1004/Save file macro

  1. #1
    Registered User
    Join Date
    04-29-2013
    Location
    Australia
    MS-Off Ver
    Excel 2010
    Posts
    8

    Run-time error 1004/Save file macro

    I am trying to set up a macro in a template that when run will set the filename and file path and save as a macro enabled document. What I need to include in the filename is text from C7 and the date from C9 e.g. 4 June 2013

    Have used the following code

    Please Login or Register  to view this content.
    When I run the macro I get the following error (the second line as highlighted above seems to be the issue).

    Run-time error 1004
    The file could not be accessed. Try one of the following


    I hope this all makes sense, because I am very much a noob when it comes to vba

    Thanks
    Last edited by egglee; 06-04-2013 at 06:23 AM.

  2. #2
    Valued Forum Contributor
    Join Date
    09-21-2011
    Location
    Birmingham UK
    MS-Off Ver
    Excel 2003/7/10
    Posts
    2,188

    Re: Run-time error 1004/Save file macro

    what is in C7 and c9 when you get the error

  3. #3
    Registered User
    Join Date
    04-29-2013
    Location
    Australia
    MS-Off Ver
    Excel 2010
    Posts
    8

    Re: Run-time error 1004/Save file macro

    A first and last name

  4. #4
    Valued Forum Contributor
    Join Date
    09-21-2011
    Location
    Birmingham UK
    MS-Off Ver
    Excel 2003/7/10
    Posts
    2,188

    Re: Run-time error 1004/Save file macro

    can you show me exactly? Is c9 todays date?

  5. #5
    Registered User
    Join Date
    04-29-2013
    Location
    Australia
    MS-Off Ver
    Excel 2010
    Posts
    8

    Re: Run-time error 1004/Save file macro

    C7 John Smith
    C9 4 June 2013

  6. #6
    Valued Forum Contributor
    Join Date
    09-21-2011
    Location
    Birmingham UK
    MS-Off Ver
    Excel 2003/7/10
    Posts
    2,188

    Re: Run-time error 1004/Save file macro

    You don't need the XLSM and you need to use the .text for the date

    Please Login or Register  to view this content.

  7. #7
    Registered User
    Join Date
    04-29-2013
    Location
    Australia
    MS-Off Ver
    Excel 2010
    Posts
    8

    Re: Run-time error 1004/Save file macro

    You are awesome thanks so much

+ 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