Popping up message box with "Make sure the specified folder exists"

vba India
  • 13 years ago

    Hi All,

    I'm running the excel file with a parameter which is a path that contains
    the files to process. After processing the files a targetfile will be created.


    I'm getting the below error only if i try to run the excel file more than once continuously. that means for the first & second time I'll get no error and afterwards I'll be getting the below error.

    The ideal no of files processed at a time 250. if it crosses this number then it'll be getting the below error. but we can't restrict the user on no of files

    Problem exist if we try to read more than 250+ files and throws popup with
    the message
    " File could not be accessed
    - Make sure the specified folder exists
    - Make sure the folder that contains the file is no read-only
    - Make sure the file name does not contain any of the following characters <
    > ? [ ] : ""
    - Make sure the file/path name does not contain more than 218 characters
    "
    with the OK button in it and hangs after that. even if we press the OK
    button it  won't get closed.

    I tried debugging the same and found the error
    " error -1004
    Method 'Open' of object 'Workbooks' failed" while opening the new file.

    After this i tried setting the object to nothing before opening the file but
    in vain.

    Can some one let me know what might be the problem & how can i solve it.

    Thanks

    Rajesh
























Post a reply

No one has replied yet! Why not be the first?

Sign in or Join us (it's free).

Contribute

Why not write for us? Or you could submit an event or a user group in your area. Alternatively just tell us what you think!

Our tools

We've got automatic conversion tools to convert C# to VB.NET, VB.NET to C#. Also you can compress javascript and compress css and generate sql connection strings.

“Nine people can't make a baby in a month.” - Fred Brooks