I have open office spreadsheet with some macro code attached to open document event. When I read and edit file and then saving afterwards all modules with macro code in document dissapears. Can gembox save macro when working with .ods format?
private async Task<Stream> FillSpreadsheet(string filePath, CancellationToken cancellationToken)
{
var workbook = ExcelFile.Load(filePath, LoadOptions.OdsDefault);
// some editing in workbook
var memoryStream = new MemoryStream() { Position = 0 };
workbook.Save(memoryStream, SaveOptions.OdsDefault);
return memoryStream;
}
Gembox.Spreadsheet Version 49.0.1623