amm getting dates as 01-01-2012 02-01-2012 03-01-2012 04-01-2012 . . .. . . ..dynamically as headers in grid from directly binding with sp
am getting data as
name type blck 01-01-2012 02-01-2012 03-01-2012 04-01-2012 . ... HEADERS
I WANT
Name type blck 01 02 03 04. ... as HEADERS
am getting data as
name type blck 01-01-2012 02-01-2012 03-01-2012 04-01-2012 . ... HEADERS
I WANT
Name type blck 01 02 03 04. ... as HEADERS
<telerik:RadGrid ID="grdBlock" runat="server" GridLines="None" AllowFilteringByColumn="False" AllowPaging="False" AllowSorting="False" AutoGenerateColumns="true" PageSize="25" OnNeedDataSource="grdBlock_NeedDataSource" Skin="Office2007" CellSpacing="1" Width="900px" EnableLinqExpressions="false" > <GroupingSettings CaseSensitive="false" /> <ExportSettings HideStructureColumns="true" IgnorePaging="true" FileName="Block" ExportOnlyData="true" OpenInNewWindow="true"> <Excel Format="ExcelML" /> </ExportSettings> <MasterTableView CommandItemDisplay="Top" AllowMultiColumnSorting="true" FilterItemStyle-HorizontalAlign="Center"> <CommandItemSettings ShowExportToExcelButton="true" ShowExportToWordButton="false" ShowExportToPdfButton="false" ShowAddNewRecordButton="false" ShowRefreshButton="false" > </CommandItemSettings> <Columns > </Columns> </MasterTableView> <ClientSettings> <Scrolling AllowScroll="True" UseStaticHeaders="True" SaveScrollPosition="True"> </Scrolling> </ClientSettings> </telerik:RadGrid>
my cs code is
protected void grdBlock_NeedDataSource(object sender, GridNeedDataSourceEventArgs e)
{
DataSet result = new DataSet();
BLEmployee bl_emp = new BLEmployee();
PropertyEmployeeMaster prop_emp = new PropertyEmployeeMaster();
try
{
prop_emp.Employee_Id = Convert.ToDecimal(ddlEmployeeName.SelectedItem.Value);
DateTime selectedDate = RadMonthYearPicker1.SelectedDate.Value;
DateTime startDate = selectedDate.AddDays((selectedDate.Day - 1) * -1);
DateTime endDate = startDate.AddDays(DateTime.DaysInMonth(startDate.Year, startDate.Month) - 1);
prop_emp.start_date = Convert.ToDateTime(startDate);
prop_emp.end_date = Convert.ToDateTime(endDate);
result = bl_emp.ReportMonthlyBlock(prop_emp);
result = bl_emp.ReportMonthlyBlock(prop_emp);
}