Hi David,
I see no problems with the table structure with the correct colgroup setting. Following is the code that I am testing:
And the dummy data:
protected
void
RadGrid1_NeedDataSource(
object
sender, GridNeedDataSourceEventArgs e)
{
DataTable table =
new
DataTable();
table.Columns.Add(
"ID"
,
typeof
(
int
));
table.Columns.Add(
"FirstName"
,
typeof
(
string
));
table.Columns.Add(
"LastName"
,
typeof
(
string
));
table.Columns.Add(
"Age"
,
typeof
(
int
));
table.Columns.Add(
"Date"
,
typeof
(DateTime));
table.Columns.Add(
"BoolValue"
,
typeof
(Boolean));
for
(
int
i = 0; i < 5; i++)
{
table.Rows.Add(i,
"FirstName"
+ i,
"LastName"
+ i, 20 + i, DateTime.Now.AddDays(i), i % 2 == 0);
}
(sender
as
RadGrid).DataSource = table;
}
protected
void
RadButton1_Click(
object
sender, EventArgs e)
{
RadGrid1.ExportToExcel();
}
Regards,
Konstantin Dikov
Telerik
Do you need help with upgrading your ASP.NET AJAX, WPF or WinForms projects? Check the
Telerik API Analyzer and share your thoughts.