This project has moved. For the latest updates, please go here.

Remove formula?

Aug 9, 2010 at 7:28 PM
Edited Aug 9, 2010 at 7:32 PM

Is there a way to unset or remove a formula currently in place for a range of cells? I tried this, but when Excel opens it, it throws a bad formatting error. "Excel found unreadable content in filename. Do you wish to recover the contents of this workbook? If you trust the source of this workbook, click yes."

 

using (var r = ws.Cells["L29:M32"])
{
	r.Value = @"n/a";
	r.Formula = "";
}
Coordinator
Aug 10, 2010 at 7:42 PM
Edited Aug 12, 2010 at 7:42 AM

That should work. I'll have a look at it.