Iron Speed Technical Forums
Register Latest Topics
 
 
 


Reply
  Author   Comment  
daredavil

Registered:
Posts: 29
Reply with quote  #1 
Hello,
could somebody help me to customize Excel export in ISD 9.2. Please, how to set font and column width to be as needed. In the code behind there is set "Default". Upon having exported I can see that Font is Arial,10. I would like e.g., Times New Roman, 14, for example..Likewise with the column width, format of the column headers. Having look into documentation, I do not know how to implement e.g., this code:

C#:

// Define a unique column style for each column in the table to be exported

if ((rowCounter == 0))

{

     CarlosAg.ExcelXmlWriter.WorksheetStyle excelColumnStyle =

     excelBook.Styles.Add((exCol.DisplayColumn.ToString() + columnCounter));

     excelColumnStyle.Font.FontName = "Verdana";

     excelColumnStyle.Font.Size = 8;

     // Set the display format for the column to be exported

     if (!exCol.DisplayFormat.Equals("Default"))

     {

          excelColumnStyle.NumberFormat = exCol.DisplayFormat;

     }

}

if (!skip) {

     excelRow.Cells.Add(new WorksheetCell(val, excelDataType, (exCol.DisplayColumn.ToString() +

     columnCounter)));

}

Where does this code is suppose to be placed?

Thanks

Previous Topic | Next Topic
Print
Reply

Quick Navigation:

Easily create a Forum Website with Website Toolbox.

Download Iron Speed Designer

Terms of Service Privacy Statement