Hi
I'm using XamScheduleDataManger in my SL5 application.
I have problem showing working hour. I set 00:00 to 23:59:59(as I didn't want to have "NOT Working hour" Highlithed) as Working hour and now the XamDayView default starting time is 00:00, and every time i need to scroll down to see my appointments.
So I've following questions:
1) How can i remove "NOT working Hour" Highlighting ? (without changing default working hours)
2) How can i set the Start time so when I show XamDayView or XamWeekView it doesn't start from 00:00 but from xx:xx
3) Where can i get the default CalendarBrushes List ? (as I tried setting BaseColor property to different colors in ResourceCalendar but it's not good looking as the default Calendar brushes)
Thank you
Hello,
Thank you for your post. I have been looking into it and for the start time I can suggest you see this forum thread:
https://ko.infragistics.com/community/forums/f/ultimate-ui-for-wpf/49730/specify-initial-visible-hour-timeslot-in-xamdayview
where it is explained how to scroll to a particular hour. As for the styling of the TimeSlotPresenter, I can suggest you see these two forum threads:
https://ko.infragistics.com/community/forums/f/ultimate-ui-for-wpf/64477/changing-the-computedbackground-timeslot-colors/326306#326306
and
https://ko.infragistics.com/community/forums/f/ultimate-ui-for-wpf/83936/set-the-style-for-working-hours
https://ko.infragistics.com/community/forums/f/ultimate-ui-for-wpf/52620/customizing-the-time-slot-panel-in-xamschedule-day-view
which will help you to restyle it. In the third one it is mentioned where you can find the default Styles and brushes of the XamSchedule. Please let me know if this helps you or you need further assistance on this matter.
Looking forward for your reply.
Hi Stefan
The sample project you attached here https://ko.infragistics.com/community/forums/f/ultimate-ui-for-wpf/83936/set-the-style-for-working-hours is form WPF and it's not working in SL, the ControlTemplate.Trigger is not present in SL.
Also I'm using IG libraries 12.1 not 13.1.
So can you kindly post me that project compatible with SL5 ?
I have modified the sample from the referred forum thread, so now the same functionality is available in SL. Basically instead of Trigger, I bound the Border's Background to the TimeslotPresenter's IsWorkingHour Property and used Converter to return different Colors. Please let me know if this helps you or you need further assistance on this matter.
Thanks for your Sample project.
Another query, how can I get the list of default DayView brushes ?
Just to add to what Stefan wrote, the Computed read-only properties exposed by the elements are the result of calculating the brushes for that element based on its state and based on the CalendarBrushProvider associated with that element. For elements that are not within the ResourceCalendar specific areas (e.g. the time slot headers), the brush provider comes from the DefaultBrushProvider of the CalendarColorSchemeResolved. For elements that are within a ResourceCalendar specific areas that are specific to a given ResourceCalendar (e.g. appointments), the brush provider comes from the BrushProvider of the associated ResourceCalendar (so that for example the Appointment shows using the BaseColor information for the calendar it is associated with). For other elements within the ResourceCalendar specific areas (e.g. timeslots), the brush provider comes from the ResourceCalendar that represents the selected calendar within the calendar group.
Once you have the brush provider you can index into it with the CalendarBrushId enum value that represents the brush you want to get.
Since the colors of the most elements are bound to Properties that begin with Computed (e.g CoputedBackgroud, ComputedBorderBrush, etc.), this means that these colors are accessible but cannot be modified, so if you want to change a particular color, you should copy its default Style and change the Binding or set the particular Background, Foreground to a static color. You can use XAML spy for example in order to examine the colors.
Hope this helps you.