I have a database table. I read some data using a query and parse it into a list of my dto:
Context.Database.SqlQuery<myDto>(sql);
Next, I want to save this data into an Excel-file using:
ExcelEngine() and worksheet.ImportData(data, 1, 1, true)
This works fine.
But I would like to have slightly different header labels.
I know I can change my Dto and my query to change the headers but I want to keep my current Dto and use some kind of attribute:
Current dto declaration:
public string MessageId { get; set; }
Suggested new dto declaration:
[XlsIO.HeaderLabel = "Message number"]
public string MessageId { get; set; }
Of course, ImportData should look at this attribute and use it when available.
Is this possible? If not can it be added to the feature request list?
I'm using v15.3.0.26
Thanks,
Paul