System.Globalization.HebrewCalendar.GetMonth C# (CSharp) Method

GetMonth() public method

public GetMonth ( System.DateTime time ) : int
time System.DateTime
return int
        public override int GetMonth(DateTime time) {
            return (GetDatePart(time.Ticks, DatePartMonth));
        }

Usage Example

Esempio n. 1
0
        public IEnumerable<ComplexZmanimCalendar> GetDaysInHebrewMonth(DateTime yearAndMonth, GeoLocation location)
        {
            Calendar calendar = new HebrewCalendar();
            var daysInMonth = calendar.GetDaysInMonth(calendar.GetYear(yearAndMonth), calendar.GetMonth(yearAndMonth));

            for (int i = 0; i < daysInMonth; i++)
            {
                var zmanimCalendar = new ComplexZmanimCalendar(location);
                zmanimCalendar.DateWithLocation.Date = new DateTime(yearAndMonth.Year, yearAndMonth.Month, i + 1);
                yield return zmanimCalendar;
            }
        }
All Usage Examples Of System.Globalization.HebrewCalendar::GetMonth