ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   add new row (https://www.excelbanter.com/excel-programming/330536-re-add-new-row.html)

NuB

add new row
 
I'm able to add a new row from code (C#) but how can i add text to the new
row that was just added?
this is what i have:

currentCell = (Excel.Range)cellCars.Cells.get_Item(location+=1,1 );
Excel.Range dRow = currentCell.EntireRow;
dRow.Insert(Excel.XlInsertShiftDirection.xlShiftDo wn, missing);
dRow.Value2 = "Total Sales";

its not entering Total Sales to the new added row in Cell A#?

what do i need to add to add Total Sales to the correct A cell?








All times are GMT +1. The time now is 09:40 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com