不同颜色的Telerik调度器预约
我正在从数据表中读取约会。这是我的密码:不同颜色的Telerik调度器预约,telerik,scheduler,Telerik,Scheduler,我正在从数据表中读取约会。这是我的密码: List<MyClass> myObjects = (from e in myEntities.Mytable where e.DateFrom >= schedulerInfo.ViewStart && e.DateTo <= schedulerInfo.ViewEnd
List<MyClass> myObjects = (from e in myEntities.Mytable where
e.DateFrom >= schedulerInfo.ViewStart &&
e.DateTo <= schedulerInfo.ViewEnd
select e).ToList();
List<Appointment> appointments = new List<Appointment>(myObjects.Count);
foreach (MyClass e in myObjects) {
Appointment a = new Appointment();
a.ID = e.ID;
a.Subject = e.Description;
a.Start = e.DateFrom;
a.End = e.DateTo;
a.BackColor = System.Drawing.Color.Yellow;
appointments.Add(a);
List myObjects=(来自myEntities.Mytable中的e,其中
e、 DateFrom>=schedulerInfo.ViewStart&&
e、 DateTo为了更改RadScheduler中约会的颜色,您必须订阅。如中所示,您所要做的就是从e.appointment
中获取当前约会对象,并定义背景颜色(和其他可用属性)您应该已经准备好了!如何将数据绑定到RadScheduler?此外,您是通过标记还是通过在代码中添加事件处理程序来订阅OnAppoitnmentDataBound事件?实际上,如果您使用Web服务填充RadScheduler,AppointDatabound将不会触发。我应该使用OnClient PointMentDataBound。