前面 动态加的列 GridDateTimeColumn GDDateTime = new GridDateTimeColumn();
this.RadGrid1.MasterTableView.Columns.Add(GDDateTime);
GDDateTime.FilterImageToolTip = "查询";
GDDateTime.DataFormatString = "{0:yyyy-MM-dd}";
GDDateTime.DataField = de.Key.ToString();
GDDateTime.HeaderText = de.Value.ToString();后面想把GridDateTimeColumn 里的RadDatePicker的属性改掉:
protected void RadGrid1_ItemDataBound(object sender, GridItemEventArgs e)
{
if(e.Item.ItemType==GridItemType.FilteringItem){
TableCell cell = e.Item.Cells[8];
(cell.Controls[0] as RadDatePicker).Calendar.FastNavigationSettings.DateIsOutOfRangeMessage = "时间超出范围";
(cell.Controls[0] as RadDatePicker).Calendar.FastNavigationSettings.OkButtonCaption = "确定";
(cell.Controls[0] as RadDatePicker).Calendar.FastNavigationSettings.TodayButtonCaption = "今天";
(cell.Controls[0] as RadDatePicker).Calendar.FastNavigationSettings.CancelButtonCaption = "取消";
}
}
this.RadGrid1.MasterTableView.Columns.Add(GDDateTime);
GDDateTime.FilterImageToolTip = "查询";
GDDateTime.DataFormatString = "{0:yyyy-MM-dd}";
GDDateTime.DataField = de.Key.ToString();
GDDateTime.HeaderText = de.Value.ToString();后面想把GridDateTimeColumn 里的RadDatePicker的属性改掉:
protected void RadGrid1_ItemDataBound(object sender, GridItemEventArgs e)
{
if(e.Item.ItemType==GridItemType.FilteringItem){
TableCell cell = e.Item.Cells[8];
(cell.Controls[0] as RadDatePicker).Calendar.FastNavigationSettings.DateIsOutOfRangeMessage = "时间超出范围";
(cell.Controls[0] as RadDatePicker).Calendar.FastNavigationSettings.OkButtonCaption = "确定";
(cell.Controls[0] as RadDatePicker).Calendar.FastNavigationSettings.TodayButtonCaption = "今天";
(cell.Controls[0] as RadDatePicker).Calendar.FastNavigationSettings.CancelButtonCaption = "取消";
}
}
解决方案 »
免费领取超大流量手机卡,每月29元包185G流量+100分钟通话, 中国电信官方发货