Auto Deleting file (contents) after 6 months.


Posted by Geo A. on January 15, 2002 5:20 PM

I would like to automatically delete a file (or the contents) if the user tries to use the file after a set date. A forced expiration.

any help would be appreciated.

Posted by bob umlas on January 15, 2002 7:05 PM

Sub Auto_Open()
If date>#3/1/2002# then
for each x in thisworkbook.sheets
x.usedrange.clear
Next
thisworkbook.save
end if
End Sub



Posted by Geo A. on January 16, 2002 10:29 AM

Whoops, you can remove:

Range("iu98").ClearContents

I left it in inadvertantly, it's of no use.

Nate