本文介绍了在wpf中显示rad计划控件上的记录。的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我一直在尝试在rad计划控制中显示员工记录,这是员工的计划任务。列是员工姓名,Start_date,工作小时数,工作标题。这些值来自一张桌子。我一直在尝试这一周仍然没有任何解决方案。请给我一个源代码。我需要这个。任何帮助都将受到高度赞赏。

I have been trying to display employee records on the rad schedule control which are scheduled task for the employees. The columns are Employee name,Start_date,hours worked,job heading. The values are coming from a table. I have been trying this from a week still have not got any solution. Please provide me a source code for this. I am in need of this. Any help would be highly appreciated.

推荐答案

AppointmentsService.AppointmentsServiceClient client = new AppointmentsService.AppointmentsServiceClient();
          DataTable dtResult = client.GetScheduledDetails();
          //DataTable dtResult = dataStore.GetScheduledDetails();
          ResourceCollection resCollection = this.resourceTypes[0].Resources;

          Telerik.Windows.Controls.ResourceType resourceType = new Telerik.Windows.Controls.ResourceType();
          resourceType.Name = "Tasks";
          resourceType.DisplayName = "Tasks";
          foreach (DataRow row in dtResult.Rows)
          {
              Telerik.Windows.Controls.Resource resource = new        Telerik.Windows.Controls.Resource();
             // resource.DisplayName = row.Field<string>("epmloyee_name");

              Appointment appointment = new Appointment
              {
                  Start = row.Field<DateTime>("jbd_datestarted"),
                 //End = row.Field<DateTime>("EndDate"),
                  Subject = row["jbd_jobheading"].ToString(),
                  //Body = row["Body"].ToString()

              };



              this.appointments.Add(appointment);
              this.resourceTypes.Add(resourceType);
          }


这篇关于在wpf中显示rad计划控件上的记录。的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!

10-28 00:17