I am in need of some assistance. Software config first..
Win 7 Ult 64, Visual Studio 2010 (VB.NET 2.0, Winforms
Scheduler Q2 2011.2.831 (Latest), VistaDB (Supported
by Telerik ORM) MS SQL 200X Compatible. I have now
"Bound" the Scheduler and I can Create new appoint
ments but save makes the "Appointments" disapear!.
Has anyone ran across this with RadScheduler? (I am
not using ORM) Just the sample .mdb database (used
by telerik example) Converted to VistaDB Format. I
added "User 1", "User2", "User 3", "User 4". to the
resources part of the database and they come up
properly but I Can't figure out the Colors Part Need
Color.Transparent in all 4 spots. I am using the code
"Ivan" Provided and it is in the samples. The "Samples"
do not provide Multi - User Data Binding. It could be a
very simple line of code to solve this problem.
Thanks in advance!,
Jeff :)
Dim
colors()
As
Color = {Color.Transparent, Color.Transparent, Color.Transparent, Color.Transparent}
Dim
names()
As
String
= {
"User 1"
,
"User 2"
,
"User 3"
,
"User 4"
}
For
i
As
Integer
= 0
To
names.Length - 1
Dim
resource
As
New
Telerik.WinControls.UI.Resource()
resource.Id =
New
EventId(i)
resource.Name = names(i)
resource.Color = colors(i)
'resource.Image = Me.imageList1.Images(i)
Me
.RadScheduler1.Resources.Add(resource)
Next
i
Me
.RadScheduler1.GroupType = GroupType.Resource
Me
.RadScheduler1.ActiveView.ResourcesPerView = 2
Catch
ex
As
Exception
8 Answers, 1 is accepted
Please find your answer in the support thread named "Multi-User Problem Example".
Should you need further assistance, do not hesitate to contact us.
Best wishes,
Ivan Todorov
the Telerik team
Q2’11 SP1 of RadControls for WinForms is available for download (see what's new); also available is the Q3'11 Roadmap for Telerik Windows Forms controls.
nothing is displayed . if you remove the grouping you can see the records with no resource . Let me know If you found a solution .
Thank you for writing.
Usually, this is caused by incorrectly set mappings when binding RadScheduler to a data source. The solution to this may vary depending on the details of your case, but generally when using a many-to-many relation between appointments and resources, you should set the Resources property of the AppointmentMappingInfo to the name of the relation and the ResourceId property to the name of the resources column in your intermediate table:
appointmentMappingInfo.Resources =
"Appointments_AppointmentsResources"
appointmentMappingInfo.ResourceId =
"ResourceID"
More information can be found in the Data Binding Walkthrough help article.
If you send me a code snippet or a sample project that demonstrates your approach, I will be able to provide you with more concrete answers.
I hope you find this helpful.
All the best,
Ivan Todorov
the Telerik team
SP1 of Q3’11 of RadControls for WinForms is available for download (see what's new).
Thanks for any help. medbiller@coqui.net
You can use the following method to set the height of the resource header:
private
void
SetHeaderHeight()
{
SchedulerDayViewGroupedByResourceElement dayView =
this
.radScheduler1.SchedulerElement.ViewElement
as
SchedulerDayViewGroupedByResourceElement;
SchedulerMonthViewGroupedByResourceElement monthView =
this
.radScheduler1.SchedulerElement.ViewElement
as
SchedulerMonthViewGroupedByResourceElement;
TimelineGroupingByResourcesElement timelineView =
this
.radScheduler1.SchedulerElement.ViewElement
as
TimelineGroupingByResourcesElement;
if
(dayView !=
null
)
{
dayView.ResourceHeaderHeight = 160;
}
if
(monthView !=
null
)
{
monthView.ResourceHeaderHeight = 160;
}
if
(timelineView !=
null
)
{
timelineView.ResourceHeaderWidth = 160;
}
}
Note that if you are switching between the views, then you should handle the ActiveViewChanged event and call that method to update the header height of the new view:
void
radScheduler1_ActiveViewChanged(
object
sender, SchedulerViewChangedEventArgs e)
{
SetHeaderHeight();
}
Hope this helps.
Greetings,
Ivan Todorov
the Telerik team
Ivan, thanks for your prompt & assertive response.
I can manage the Day & Month views pretty well using the code you supplied, but the Time line gives the following error:
An exception of type 'System.ObjectDisposedException' occurred in mscorlib.dll and wasn't handled before a managed/native boundary
Additional information: Cannot access a closed Stream.
If I set timelineView.ResourceHeaderWidth = between 0 & 22 on a maximized form it won’t give the error but it’ll show very little of the image. Values for timelineView.ResourceHeaderWidth range from 0 to 2 without error when the form is not maximized.
Also I couldn’t find a SchedulerWeekViewGroupedByResourceElement class to implement the same technique for the week view. Thanks again.
I was not able to reproduce the described exception. However, we have encountered some weird exceptions when setting resource images to TimelineView. As far as we know, the cause is an issue in the GDI+ rendering engine and it is triggered because in TimelineView, the images are rotated. To overcome the issue, simply call:
this
.radScheduler1.SchedulerElement.SetResourceHeaderAngleTransform(SchedulerViewType.Timeline, 0);
As to the SchedulerWeekViewGroupedByResourceElement, there is no such element because the WeekView uses the SchedulerDayViewGroupedByResourceElement with day count of 7. This was implemented this way because the appearance of DayView and WeekView is very similar. The snippet provided in my previous post should work for both views.
Let me know if I can assist you further.
Kind regards,
Ivan Todorov
the Telerik team