Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Shaun E on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Undo in Excel VBA???

Status
Not open for further replies.

MigrantFirmWorker

Programmer
Apr 9, 2003
54
US
Anybody know how to undo the actions of an Excel macro?

Chris

-------------------------------------------------------------
"Don't be deceived. We're all temporary employees.
 
As far as I'm aware it can't really be done.

This is where I sit back and find out I'm totally wrong!!

I seem to recall other threads on this but not a solution.

Happy Friday
;-)

If a man says something and there are no women there to hear him, is he still wrong? [ponder]
The faqs ma'am, just the faqs. Get the best from these forums : faq222-2244
 
Oh well...At least it's Friday.

Chris

-------------------------------------------------------------
"Don't be deceived. We're all temporary employees.
 
I do not think it is possible to "undo" steps in a macro. At run-time, they are simply instructions. The macro does them.

You may build more instructions to do something else, to fix something. Perhaps toggle something back again, but "undo"? No.

This is why we do error trapping. And why error trapping is more often than not, the most difficult and time consuming. because we have to think ....what if this is wrong, and I would like to.....undo? We can't, so we have to try and get it right.

Gerry
 
The only way to undo a macro is to have another macro that does the "undo" for you - and that would have to be written before you ran the macro that changed everything. There is no built in functionality to achieve this. Only other option would be to recover the file form network backup (if that wouldn't mean losing too much work)

Rgds, Geoff

Never test the depth of water with both feet

Help us to help you by reading FAQ222-2244 before you ask a question
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top