Denis Cilliers
Top achievements
Rank 1
Denis Cilliers
asked on 04 Jan 2013, 10:48 AM
Why would dragging an appointment in Month-View reset the times for the Appointment
While dragging the appointment in the Week-view or the Day-view does not change the times
How would I resolve this?
While dragging the appointment in the Week-view or the Day-view does not change the times
How would I resolve this?
3 Answers, 1 is accepted
0
Hello Denis,
Thank you for contacting us.
It appears that this is an issue in the dragging behavior of RadScheduler. The issue has been logged and we will address it in a next release. Here you can track the PITS item: http://www.telerik.com/support/pits.aspx#/public/winforms/13950. For the time being, you can modify this behavior by creating a custom AppointmentDraggingBehavior. Here is how this can be achieved:
Your Telerik points have been updated. Feel free to ask if you have any further questions.
All the best,
Ivan Todorov
the Telerik team
Thank you for contacting us.
It appears that this is an issue in the dragging behavior of RadScheduler. The issue has been logged and we will address it in a next release. Here you can track the PITS item: http://www.telerik.com/support/pits.aspx#/public/winforms/13950. For the time being, you can modify this behavior by creating a custom AppointmentDraggingBehavior. Here is how this can be achieved:
public
partial
class
Form1 : Form
{
public
Form1()
{
InitializeComponent();
this
.radScheduler1.SchedulerElement.DragDropBehavior =
new
MyDraggingBehavior(
this
.radScheduler1.SchedulerElement);
}
}
class
MyDraggingBehavior : AppointmentDraggingBehavior
{
public
MyDraggingBehavior(RadSchedulerElement element)
:
base
(element) { }
public
override
bool
Move(DateTime newDate)
{
if
(
this
.Scheduler.ActiveViewType == SchedulerViewType.Month)
{
newDate = newDate.Add(
this
.ActiveFeedback.AssociatedAppointment.Start.TimeOfDay);
}
return
base
.Move(newDate);
}
}
Your Telerik points have been updated. Feel free to ask if you have any further questions.
All the best,
Ivan Todorov
the Telerik team
Q3'12 SP1 of RadControls for WinForms is out now. See what's new.
0
Denis Cilliers
Top achievements
Rank 1
answered on 09 Jan 2013, 09:45 AM
Hi Ivan
Thanks for the workaround, I will give it a bash in VB.net
:)
Thanks for the workaround, I will give it a bash in VB.net
:)
0
Accepted
Hello Denis,
Here is the same code in VB:
In such cases you can use our online C#-to-VB converter located at http://converter.telerik.com/.
If you have any future questions, do not hesitate to ask.
Regards,
Ivan Todorov
the Telerik team
Here is the same code in VB:
Public
Partial
Class
Form1
Inherits
Form
Public
Sub
New
()
InitializeComponent()
Me
.radScheduler1.SchedulerElement.DragDropBehavior =
New
MyDraggingBehavior(
Me
.radScheduler1.SchedulerElement)
End
Sub
End
Class
Class
MyDraggingBehavior
Inherits
AppointmentDraggingBehavior
Public
Sub
New
(element
As
RadSchedulerElement)
MyBase
.
New
(element)
End
Sub
Public
Overrides
Function
Move(newDate
As
DateTime)
As
Boolean
If
Me
.Scheduler.ActiveViewType = SchedulerViewType.Month
Then
newDate = newDate.Add(
Me
.ActiveFeedback.AssociatedAppointment.Start.TimeOfDay)
End
If
Return
MyBase
.Move(newDate)
End
Function
End
Class
In such cases you can use our online C#-to-VB converter located at http://converter.telerik.com/.
If you have any future questions, do not hesitate to ask.
Regards,
Ivan Todorov
the Telerik team
Q3'12 SP1 of RadControls for WinForms is out now. See what's new.