Inside the OnExcelExportCellFormatting instead of having to assign the "UniqueName":
if (e.FormattedColumn.UniqueName == "Freight")
{
e.Cell.Style["mso-number-format"] = @"0";
}
Could we not Style all the datatype fields of date be automatically formated to the date format that you want?
1 Answer, 1 is accepted
0
Daniel
Telerik team
answered on 05 Jun 2009, 08:47 AM
Hello Robert,
You could either set the mso-number-format to the desired columns only (as you did) or skip the conditional check and stylize all the columns with the same style. Unfortunately it's not possible to assign default styles in advance.