title: How to Access the Undo Stack in Excel from C# via Office Interop?
body: <p>I'm building a C# app that needs to interact with an Excel spreadsheet via Office Interop.  I'd like to gain access to the full Undo stack so I can make a series of changes to the worksheet and then roll them back one at a time if necessary.  I see that the Word Document object in the Interop assemblies has UndoRecord and some other niceties, including an Undo function.  For example, I can call Microsoft.Office.Interop.Word._Document.Undo() with a parameter to undo multiple actions.  Excel's Undo stuff, on the other hand, looks much more limited.  Sure, there's Microsoft.Office.Interop.Excel._Application.Undo(), but it goes only one action deep, and if called again performs a "Redo" instead of going deeper down the stack.</p>
  
  <p>I've found code online where VBA developers coded their own Undo histories for Excel because that was the only way to get the desired functionality.  I don't see anything like this for C#, though.  Is there any way to mimic the way Word's Interop undo works in Excel?</p>