Page tree

Welcome to FreeSoftwareServers Confluence Wiki

Skip to end of metadata
Go to start of metadata
Sub IfFileExists()
If Not Dir("C:\Temp\test.xlsx", vbDirectory) = vbNullString Then
    MsgBox "exists"
    Kill "C:\Temp\test.xlsx" ' Now Re-Run Sub to Test!
Else
    MsgBox "does not exist"
End If


  • No labels