Free Support Forum - aspose.com

Smart markers for multiple worksheets

Using Smart Marker approach how do I create new worksheet for each record in the data table.

I have a stored procedure that returns two tables. Master table and Detail table. For each row in the master table there should new worksheet and corresponding detail should also be render on that worksheet. For example

Master Table

PersonID Person Name

----------------------------------------

1 Joe

2 Brent

3 Sam


Detail Table

PersonID Car Name

------------------------------------------

1 Infinity G5

1 Audi R8

2 Toyota Camry

3 GM

3 Ferrari


Considering example above the excel should create three worksheet, with Person name as header and corresponding Car Name as details.

I know I can do that programmatically, but I was looking if I can do that using smart marker approach

Hi,

Thanks for your posting and using Aspose.Cells for .NET.

We are afraid, this is not possible with SmartMarkers. You will have to do it programmatically. SmartMarkers cannot create new worksheets.

Thanks.

I know smartmarkers cannot create new worksheet, but is it possible to add smart markers dynamically on each worksheet and set the datasource?

Also, is it possible to set datasource just for single worksheet?

Hi,

Thanks for your posting and using Aspose.Cells.

Yes, you can add smart marker tags dynamically in each worksheet and then process them. However, your data source should be different in each worksheet.

If your single datasource exist in multiple worksheet, all of the worksheets’ data will be processed.