This is a migrated thread and some comments may be shown as answers.

Group By Resources - Displays multiple Entries

2 Answers 31 Views
Scheduler
This is a migrated thread and some comments may be shown as answers.
Shanmugam Narasimhan
Top achievements
Rank 1
Shanmugam Narasimhan asked on 06 Jan 2015, 01:24 AM
Hi
I am new to using Scheduler with Group By resources. I have created the page with all the necessary data. But the Scheduler displays multiple entries for the resources. 

You can see my multiple appointments  for resource Mary, though there is only one entry in the database
My Server side code as follows:

    Protected Sub Page_Load(sender As Object, e As EventArgs) Handles Me.Load
        If Not IsPostBack Then
            'Dim ParamCol = New ParameterCollection
            'ParamCol.Add("Date", Now)
            Dim ds As DataSet = zDataFactory.GetAppointmentListAll()
            RadScheduler1.SelectedDate = Convert.ToDateTime(Now)
            RadScheduler1.SelectedView = SchedulerViewType.DayView
            RadScheduler1.TimelineView.NumberOfSlots = 10
            RadScheduler1.DataSource = ds
            RadScheduler1.DataKeyField = "AppointmentID"
            RadScheduler1.DataStartField = "FromTime"
            RadScheduler1.DataEndField = "ToTime"
            RadScheduler1.DataSubjectField = "ServiceDescription"
            RadScheduler1.GroupBy = "Consultant"
            RadScheduler1.GroupingDirection = GroupingDirection.Horizontal
            
            Dim rt As New ResourceType("Consultants")
            rt.ForeignKeyField = "ConsultantID"
            rt.KeyField = "ConsultantID"
            rt.TextField = "ConsultantName"
            rt.Name = "Consultant"
            rt.AllowMultipleValues = False
            rt.DataSource =zDataFactory.GetConsultantList()
            RadScheduler1.ResourceTypes.Add(rt)

         End If
    End Sub

The data this is returned by the zDataFactory.GetAppointmentListAll()

Where it is going wrong?

2 Answers, 1 is accepted

Sort by
0
Shanmugam Narasimhan
Top achievements
Rank 1
answered on 06 Jan 2015, 01:26 AM
Attaching the data associated with the resource and appointment.
0
Shanmugam Narasimhan
Top achievements
Rank 1
answered on 07 Jan 2015, 03:36 AM
Problem solved!
It was due to the Resource naming.
Tags
Scheduler
Asked by
Shanmugam Narasimhan
Top achievements
Rank 1
Answers by
Shanmugam Narasimhan
Top achievements
Rank 1
Share this question
or