As I am new to Aspose as well as oracle , facing trouble in generating excel.I want to generate a excel file from aspose .net. The problem of mine is as follows:
I have a data in coming out from oracle database in the following format:
Supervisor_Name Tel_No Assigned_Date Emp_Name Job Color
Jacob Andrew 121 10/10/2016 Robert A11 Green
Jacob Andrew 123 10/10/2016 David A12 Red
John 214 10/10/2016 Kristen A13 Blue
John 32211 11/10/2016 Garry B11 Orange
John 55454 11/10/2016 Martin B32 Blue
For this I have joined multiple tables based on the requirement.
The problem is , I want this data in Excel in the following manner:
Mon Tue
10 11
**Supervisor_Name Emp_Name**
Jacob Andrew
00121 Robert A11
00123 David A12
John
Kristen A13
Garry B11
Martin B32
I am not able to fetch the data in this format from oracle as well, if that would have worked it could have easier my code. But now as i am unable to fetch the data in the manner described above, Please suggest me a way by which i can accomplish this.
I am trying to achieve this in code side but stuck somewhere because of architecture.
public static DataTable ConvertListToDataTable<T>(List<T> sourceList, List<ExcelCol> col)
{
DataTable ExDataTable= new DataTable(typeof(T).Name);
DataRow newRow = null;
Dictionary<string,List<string>> dictCheck = new Dictionary<string,List<string>>(); // For adding a supervisor and his corresponding records
return ExDataTable;
}
What i am doing is trying to convert the data in data table in the format i want. But that doesn't seems to help me. Please can anyone suggest me a way/ approach to do this kind of task. Any help from anyone would be highly appreciated. Regards,
Please post this issue in Aspose.Cells forum as we need to investigate this issue thoroughly. We will look into it and suggest you a sample code or workaround to deal with it.
Note: I am working as Developer Evangelist at Aspose