I use Infragistics v13.2. vs2013. vb.net
I want to show that "New Year" in the holidays calendar.
How can I do?//
my code is..
Dim AP As Infragistics.Win.Appearance ' Create an Appearance for each holiday AP = Me.ultraCalendarLook1.Appearances.Add("New Year's Day") AP.ForeColor = Color.Red AP.FontData.Bold = Infragistics.Win.DefaultableBoolean.False AP.ImageBackground = ImageList2.Images(0) AP.ImageHAlign = Infragistics.Win.HAlign.Left AP.ImageVAlign = Infragistics.Win.VAlign.Middle ultraCalendarLook1.DaysOfYearLook(YearMonthEnum.January, 1).Appearance = _ Me.ultraCalendarLook1.Appearances("New Year's Day")
ultraCalendarLook1.DaysOfWeekLook(DayOfWeekEnum.Sunday).Appearance = Me.ultraCalendarLook1.Appearances("New Year's Day")
UltraMonthViewSingle1.CalendarLook = ultraCalendarLook1
and...
I want to be automatically activated at the current time in the Dayview.
like this..
Hello MIN,
So you should add this day in the Holidays collection you could use code like:
Dim calendarInfo = UltraMonthViewSingle1.CalendarInfo
calendarInfo.Holidays.Add(New DateTime(2016, 1, 1), "New Year")
about UltraDayView you could use EnsureTimeSlotVisible method :
UltraDayView1.EnsureTimeSlotVisible(DateTime.Now, True)
Please let me know if you have any further questions.
oh. It was very simple way.
Thank you so much.