Hi,
I'm using the example http://demos.telerik.com/silverlight/#SpreadProcessing/RadGridViewIntegration to implement an Excel export for my RadGridView.
How can I format a string to a text column in Excel? I have a value of "001" and if I use
it uses a NumberCellValue internally (because it thinks that "001" is a number") and formats the cell as a number instead of text and puts "1" instead of "001" into the Excel file.
Since the constructor of TextCellValue is internal (I have no clue why) I can't even create an instance of this type. CellValueFactory creates a NumberCellValue, too. So I'm basically stuck here. Is there any way for FORCING my cell to use the string as it is and format it as text in Excel so that I can have the "001" as the cell value?
I'm using the example http://demos.telerik.com/silverlight/#SpreadProcessing/RadGridViewIntegration to implement an Excel export for my RadGridView.
How can I format a string to a text column in Excel? I have a value of "001" and if I use
worksheet.Cells[currentRowIndex, currentColumnIndex].SetValue((
string
)value);
it uses a NumberCellValue internally (because it thinks that "001" is a number") and formats the cell as a number instead of text and puts "1" instead of "001" into the Excel file.
Since the constructor of TextCellValue is internal (I have no clue why) I can't even create an instance of this type. CellValueFactory creates a NumberCellValue, too. So I'm basically stuck here. Is there any way for FORCING my cell to use the string as it is and format it as text in Excel so that I can have the "001" as the cell value?