Window's error message

T

Thomas

How do you disable error message: "windows cannot delete
file, because it cannot be found". When running a 2 macro
which is created to verify a file and delete it.
 
S

Steve Schapel

Thomas,

As far as I know, you can't disable the error message. The only way
around this situation that I can think of, is to have a Make-Table query
which you run in your macro, using a OpenQuery action, before the
DeleteObject, to create a table with the name you are trying to delete.
If the table already exists, the Make-Table will overwrite it... but
that doesn't matter because it's getting trashed anyway. And if it
doesn't already exist, it will now. Either way, the Delete will go
ahead. You will probably want to also put a SetWarnings,No action in
the macro ahead of the OpenQuery, to suppress the display of the action
query confirmation messages.
 

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

Top