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

Determine Scheduler Cell Contents on DragOver

2 Answers 54 Views
Scheduler and Reminder
This is a migrated thread and some comments may be shown as answers.
Clyde
Top achievements
Rank 2
Clyde asked on 23 Nov 2012, 12:30 PM
Hello, 

I am attempting to determine whether the cell over which the pointer is currently hovering contains an appointment during the DragOver event. 

So far I have the code below and I believe (probably mistakenly) that the SchedulerCellElement may hold the key to determining the contents of a cell. 

Private Sub rs_DragOver(sender As Object, e As System.Windows.Forms.DragEventArgs) Handles rs.DragOver
        Try
            Dim p As Point = rs.PointToClient(New Point(e.X, e.Y))
 
            Dim t As DayViewAppointmentsTable = TryCast(rs.SchedulerElement.ViewElement, SchedulerDayViewElement).DataAreaElement.Table
 
            Dim sce As SchedulerCellElement = SchedulerUIHelper.GetCellAtPoint(p, t.Children)
Catch ex As Exception
 
        End Try
End Sub

Any ideas?

Thank you very much. 

Clyde

2 Answers, 1 is accepted

Sort by
0
Clyde
Top achievements
Rank 2
answered on 26 Nov 2012, 01:28 PM
Just in case anyone is interested I resolved this by obtaining the date from the SchedulerCellElement and checking to see if an appointment exists within that time frame. 
0
Stefan
Telerik team
answered on 28 Nov 2012, 12:11 PM
Hello Clyde,

I am writing to confirm that is the correct way to check whether a cell has an appointment in it.

I hope this helps.

All the best,
Stefan
the Telerik team
Q3’12 of RadControls for WinForms is available for download (see what's new). Get it today.
Tags
Scheduler and Reminder
Asked by
Clyde
Top achievements
Rank 2
Answers by
Clyde
Top achievements
Rank 2
Stefan
Telerik team
Share this question
or