My advice is to use the free NuGet package SpreadSheetLight. In the following code sample, the list parameter can be any type.
public static (bool success, Exception exception) InsertColumnData(
string fileName,
int row,
int column,
List<string> list)
{
try
{
using (var document = new SLDocument(fileName, "Sheet1"))
{
for (int index = 0; index < list.Count; index++)
{
document.SetCellValue(SLConvert.ToCellReference(row, column), list[index]);
row++;
}
document.Save();
return (true, null);
}
}
catch (Exception exception)
{
return (false, exception);
}
}
Usage kept simple
var (success, exception) = InsertColumnData(
"SomeFile.xlsx", 4,5, new List<string>()
{
"A", "B", "C", "D",
});
if (success)
{
// done
}else if (exception != null)
{
// inspect
}