This project has moved and is read-only. For the latest updates, please go here.

Is there a way to clear all the cell values in the sheet?

Jan 13, 2011 at 10:31 PM


I want to clear all the cells before I write values to the excel sheet.

Can someone help me ?

I tried 

workSheet.Cells[workSheet.Dimension.Start.Row, workSheet.Dimension.End.Column].Clear();


But that did not help. :(

If someone has a better idea, please let me know



Srikanth Kambhampati

Jan 13, 2011 at 10:42 PM

Got that with some help from documentation


workSheet.Cells[workSheet.Dimension.Start.Row, workSheet.Dimension.Start.Column, workSheet.Dimension.End.Row, workSheet.Dimension.End.Column].Clear();                    


Wonderful library...



Srikanth Kambhampati