You declare lastRow1 to be an int, and then you try to explicitly cast it to a Excel Range
lastrow1 = (Microsoft.Office.Interop.Excel.Range)workSheet.UsedRange.Rows.Count;
Surely you can see the error here. The error is telling you exactly what is wrong. Seriously -
read the error.