I've now stated looking at this code instead, but am still not sure how to specify any extension, i.e...
FileName.AnyExtension
Dim KillFile As String
KillFile = "c:\temp\temp.doc"
'Check that file exists
If Len(Dir$(KillFile)) > 0 Then
'First remove readonly attribute, if set...
Hi,
I've got this code which deletes a file using VB:
Dim FileToDel As String
FileToDel = "C:\SomeFileName.txt"
If System.IO.File.Exists(FileToDel) = True Then
System.IO.File.Delete(FileToDel)
MsgBox("File has been successfully deleted")
End If
Is there a way to delete a collection of...
Hello,
I am quite new to this so bare with me...
I have some code which works but I would like to add an error checking facility...
I wont go into detail on the code as I dont think it is necessary and I think all I require is something simple.
I have an user input box where the user enters...
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.