It is not possible to make a read-only cell in excel.
What you can do in your C # code, define a cell that will be read-only in a variable or list, subscribe to the SheetChange event in the SheetChange event, if that cell changes, just discard that change.
Private List example readOnlyCells = new List ();
private void OnActiveSheetCellChange(object changedSheet, Excel.Range changedCell) { if (readOnlyCells.Contains(changedCell)) changedCell.Value = string.Empty;
Update
Another alternative is to use data validation:
changedCell.Validation.Add(Excel.XlDVType.xlValidateCustom, Type.Missing, Type.Missing, "\"\"");
Using it, you will have less control, and the cell simply will not accept any input.
source share