Imports System.Diagnostics Imports Infragistics.Win Imports Infragistics.Win.UltraWinSchedule Private Sub Button6_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button6.Click ' Use the date associated with today and find its DayOfYear index. Dim todaysDate As DateTime = DateTime.Today Dim dayOfYearIndex As Integer = UltraCalendarLook.DayOfYearIndexFromMonthAndDay(todaysDate.Month, todaysDate.Day) Debug.WriteLine("The day of year index for today (" + todaysDate.ToShortDateString() + ") is: " + dayOfYearIndex.ToString()) End Sub
using System.Diagnostics; using Infragistics.Win; using Infragistics.Win.UltraWinSchedule; private void button6_Click(object sender, System.EventArgs e) { // Use todays date and find its DayOfYear index. DateTime todaysDate = DateTime.Today; int dayOfYearIndex = UltraCalendarLook.DayOfYearIndexFromMonthAndDay(todaysDate.Month, todaysDate.Day); Debug.WriteLine("The day of year index for today (" + todaysDate.ToShortDateString() + ") is: " + dayOfYearIndex.ToString()); }
Target Platforms: Windows 10, Windows 8.1, Windows 8, Windows 7, Windows Server 2012, Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server 2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or later), Windows Server 2003 SP2