DeleteFile Method

  • Thread starter Thread starter don
  • Start date Start date
D

don

I have a db IV file passed to Excel from Approach.
I need to delete the file once I have copied the data into excel.

Excel Help says:

object.DeleteFile filespec[, force]

object Required. Always the name of a FileSystemObject.

I have no idea what the FileSystemObject would be.

Any help would be appreciated.

Thanks
Don
 
Don,

You got into the help file for the Microsoft Scripting Runtime.
Its script works seamlessly with Excel.
However, using VBA the "Kill" statement will remove a file.
It cannot be used to delete an open file.
The syntax is very simple...

Kill "MyFileName.xls"

Note: do not use a wild card character in the file name as you
could delete every xls file in the folder.
--
Jim Cone
San Francisco, USA
http://www.realezsites.com/bus/primitivesoftware


"don" <[email protected]>
wrote in message
I have a db IV file passed to Excel from Approach.
I need to delete the file once I have copied the data into excel.

Excel Help says:

object.DeleteFile filespec[, force]

object Required. Always the name of a FileSystemObject.

I have no idea what the FileSystemObject would be.

Any help would be appreciated.

Thanks
Don
 

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