Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
validate a directory or file exits
How do I validate if a file exists without using On Error Resume Next then
trying to open it? |
#2
Posted to microsoft.public.excel.programming
|
|||
|
|||
validate a directory or file exits
if dir("C:\Myfolder\Myfile.xls") = "" then
msgbox "It doesn't exist" exit sub Else workbooks.Open c:\Myfolder\Myfile.xls" End if -- Regards, Tom Ogilvy "Simon Shaw" wrote in message ... How do I validate if a file exists without using On Error Resume Next then trying to open it? |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
How can I validate my Excel password against a INI file | Excel Worksheet Functions | |||
file save error: the file or directory cannot be created | Excel Discussion (Misc queries) | |||
Excel should let me sort the file directory when saving a file | Excel Discussion (Misc queries) | |||
Excel Exits on File Close with Outlook | Excel Discussion (Misc queries) | |||
get path - save new file - same sub-directory as existing file | Excel Programming |