Hi, here's what I tried but I got empty results in the worksheet (smartmarkers were removed on process).
My guess is that when you are using reflection, maybe you are not getting the public properties ?
Note: report object below is a class that creates the designer workbook and opens a template. Everything else works okay. So, maybe you can take a look at my example and see if you can copy and paste the code where I create a list and call setdatasource, process....
thanks
Marty
public class MyProduct
{
public string Name { get; set; }
public int Age { get; set; }
}
private void TestImportCustomObject(
ExcelOutputReport report)
{
Aspose.Cells.Worksheet w = report.Workbook.Worksheets["Custom"];
w.Cells["A1"].PutValue("Test");
w.Cells["A2"].PutValue("&=MyProduct.Name");
List<MyProduct> plist = new List<MyProduct>();
plist.Add (new MyProduct { age = 43, Name = "Marty" });
plist.Add(new MyProduct { age = 41, Name = "Ellen" });
report.WorkbookDesigner.SetDataSource("MyProduct", plist);
report.WorkbookDesigner.Process(false);
}