Dear Slacker007, CB Sharma!
First, thank you for your help 2.
The help of the two of you is very helpful for me.
Thanks to your help, my problem was solved.
Code demo:
Excel.Range range = worksheet.UsedRange;
int rowcount = range.Rows.Count;
for (int i = 1; i < rowcount; i++)
{
Excel.Range rg = worksheet.get_Range("A" + i.ToString());
if (Convert.ToString(rg.Value2)==null)
{
((Excel.Range)worksheet.Range["A" + i.ToString(), _columnEnd + i.ToString()]).EntireRow.Delete(null);
i--;
rowcount--;
}
}