Is it possible to rename a cell, like “A1” to “firstCell” in C#.?am using Microsoft.Office.Interop.Excel,
private void rename_btn_Click(object sender, EventArgs e)
{
misValue = System.Reflection.Missing.Value;
xlApp = new Excel.ApplicationClass();
xlWorkBook = xlApp.Workbooks.Open(xlFilename, 0, false, 5, "", "", true, Microsoft.Office.Interop.Excel.XlPlatform.xlWindows, "\t", true, false, 0, true, 1, 0);
Excel.Range r = xlWorkSheet.get_Range("A1", "A1");
//rename cell "A1"
xlWorkBook.Close(true, misValue, misValue);
xlApp.Quit();
}
You should be able to set the name of the cell range r, something similar to
then you save and should be ok.