LightCells API

Hi,

I want to read one designer using lightcells API and get values from database and fill the values into designer workbook.

I want read and write value in excel with Lightcells API to reduce the memory usage.

I have attached the data file and designer with this Post.

I used like this only for read and write in designer

C#

Workbook data = new Workbook(myDir + “Data.xlsx”);

Cells cells = data.Worksheets[0].Cells;

//Export data to DataTable
DataTable table = data.Worksheets[0].Cells.ExportDataTable(0, 0, cells.MaxDataRow +1 , cells.MaxDataColumn +1, true);

//Rename the DataTable name to match the Smart Markers

table.TableName = “source”;

//Create WorkbookDesigner object

WorkbookDesigner designer = new WorkbookDesigner();

//Open the template file (which contains Smart Markers)


designer.Workbook = new Workbook(myDir + “designer.xlsx”);

//Set the DataTable as the data source

designer.SetDataSource(table);

//Process the Smart Markers to fill the data into the worksheet

designer.Process(true);

//Calculate all formulas

designer.Workbook.CalculateFormula();

//Save the result

designer.Workbook.Save(myDir + “output.xlsx”, SaveFormat.Xlsx);


Tell how to change this in Lightcells API. I check your sample. Please help me in this process

Best Regards,
Jaganlal.R.M

Hi Jaganlal,

Thanks for your posting and using Aspose.Cells.

We will evaluate your issue and see if Smart Markers could be used in the LightCells mode. We have logged this issue in our database for investigation. We will look into it and provide you a sample code if possible. Once, there is some update for you, we will let you know asap.

This issue has been logged as CELLSNET-42604.

Hi Jaganlal ,

We have evaluated your issue/ requirements a bit. Well, we might not support this feature at the moment or even in near future. To keep settings and formattings for those expanded rows/cells with data fetched from datasource, many cells/rows/columns are inserted into the worksheet globally and dynamically, I am afraid, this situation is not suitable for LightCells mode.

Thank you.