"Undoable/Redoable" Macro

3sylvain

New Member
Joined
Mar 27, 2013
Messages
5
Hello,

I have implement several simple VBA macro which use basic excel command like copy, paste, reformatting, coloring, etc...
My issue is that I would like them to be added to the "do/undo stack", so that when I press Ctrl+Z/Ctrl+Y I can cancel and redo the macro.

I am using Excel 2003


Thanks for your help!
 

Excel Facts

Save Often
If you start asking yourself if now is a good time to save your Excel workbook, the answer is Yes

HaHoBe

Well-known Member
Joined
Jan 24, 2003
Messages
1,467
Office Version
  1. 2019
Platform
  1. Windows
Hi, 3sylvain,

no macro action is ever part of that stack - if you are working with events you may undo them. Only solution I know so far: keep a copy of the original sheet or store that in memory/array (but that could be quite a bunch of information).

Last possibility would be not to save the workbook if closed if any action needs to be undone.

Ciao,
Holger
 
Upvote 0

3sylvain

New Member
Joined
Mar 27, 2013
Messages
5
Hi Hahobe,

ok, I was hoping it would be easily do able, it would have simplified my life.
I know that I can not do it, at least not with some pain that I evaluate to be too much :)

Again, thanks for your help.
 
Upvote 0

Forum statistics

Threads
1,196,010
Messages
6,012,841
Members
441,733
Latest member
MartijnB

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Top