+ Reply to Thread
Results 1 to 9 of 9

Runtime error 53 on filecopy

  1. #1
    Registered User
    Join Date
    10-08-2013
    Location
    california
    MS-Off Ver
    Excel 2010
    Posts
    27

    Angry Runtime error 53 on filecopy

    I am running a macro to copy a list of 120k files in column A to a new folder path in column B. I tested it before running and it skipped temp files and files that did not exist in the source directory. Here is the code:

    Please Login or Register  to view this content.
    I set it to run last night and this morning found a "Runtime error '53' file not found" on FileCopy c.Value, c.Offset(0, 1).Value at line 5.8k. I need this up and running ASAP. Can anyone tell me why this happened?

    edit: the file it stopped on does exist, not that it should matter.
    Last edited by mwilkes; 11-22-2013 at 12:49 PM.

  2. #2
    Forum Expert judgeh59's Avatar
    Join Date
    02-07-2013
    Location
    Boise, Idaho
    MS-Off Ver
    Excel 2016
    Posts
    2,310

    Re: Runtime error 53 on filecopy

    is it possible that, that particular file has different permissions and you aren't allowed to do a copy....just shooting in the dark
    Ernest

    Please consider adding a * if I helped

    Nothing drives me crazy - I'm always close enough to walk....

  3. #3
    Registered User
    Join Date
    10-08-2013
    Location
    california
    MS-Off Ver
    Excel 2010
    Posts
    27

    Re: Runtime error 53 on filecopy

    I am owner of the directory.

  4. #4
    Forum Expert judgeh59's Avatar
    Join Date
    02-07-2013
    Location
    Boise, Idaho
    MS-Off Ver
    Excel 2016
    Posts
    2,310

    Re: Runtime error 53 on filecopy

    understood, but are file permissions different

  5. #5
    Registered User
    Join Date
    10-08-2013
    Location
    california
    MS-Off Ver
    Excel 2010
    Posts
    27

    Re: Runtime error 53 on filecopy

    Checked permissions on every file in the subfolder, not just the one in question. Full control on all users. There was a permissions issue with one folder but I manually set them one by one and they are not even in this batch of files to be copied. It must be something else.

  6. #6
    Forum Expert judgeh59's Avatar
    Join Date
    02-07-2013
    Location
    Boise, Idaho
    MS-Off Ver
    Excel 2016
    Posts
    2,310

    Re: Runtime error 53 on filecopy

    that was my only idea....sorry....

  7. #7
    Registered User
    Join Date
    10-08-2013
    Location
    california
    MS-Off Ver
    Excel 2010
    Posts
    27

    Re: Runtime error 53 on filecopy

    That's ok. I can usually figure these out by myself but I'm stumped. File exists, permissions are good, the code skips files that don't exist so even if the path was bad it should have kept running. I don't get it.

  8. #8
    Registered User
    Join Date
    10-08-2013
    Location
    california
    MS-Off Ver
    Excel 2010
    Posts
    27

    Re: Runtime error 53 on filecopy

    Is there any addition I can make to the code to skip to next line if this error pops up?

  9. #9
    Registered User
    Join Date
    10-08-2013
    Location
    california
    MS-Off Ver
    Excel 2010
    Posts
    27

    Re: Runtime error 53 on filecopy

    Will on error resume next work?

+ 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. [SOLVED] VBA Error: Runtime Error 1004: AutoFilter method of Range class failed
    By jl22stac in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 10-03-2013, 07:27 PM
  2. Filecopy Runtime Error 75
    By Ken S in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 12-01-2011, 08:34 PM
  3. Error using VBA FileCopy Function
    By AnthonyWB in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 07-20-2010, 03:03 PM
  4. runtime error 3265 error in a VBA Query to pull info from ERP Database
    By NBVC in forum Excel Programming / VBA / Macros
    Replies: 13
    Last Post: 05-12-2010, 03:59 PM
  5. FileCopy Command Giving "Subscript Out of Range" Error Message
    By Jim Hagan in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 06-15-2005, 02:05 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