Check if Workbook Exists

  • Thread starter Thread starter dimm
  • Start date Start date
D

dimm

Hi agin! :)

The user of my workbook has to save the old version as 'Myworkbook2 in the
specified folder before running my upgrade, and I need to check that they
have befre running the procedure.

Does anyone know how to check if the following workbook esists?

C:\Program Files\My Program\Data\Myworkbook.xls

Thanks for any ideas.....
 
Sub sssssstitw()
If Dir("C:\Program Files\My Program\Data\Myworkbook.xls") = "" Then
MsgBox ("not there")
Else
MsgBox ("is there")
End If
End Sub
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top