188 references to Year
mscorlib (50)
system\currenttimezone.cs (2)
98DaylightTime daylightTime = GetDaylightChanges(time.Year); 239return new TimeSpan(TimeZone.CalculateUtcOffset(time, GetDaylightChanges(time.Year)).Ticks + m_ticksOffset);
system\datetime.cs (3)
246if (!IsValidTimeWithLeapSeconds(dt.Year, dt.Month, dt.Day, dt.Hour, dt.Minute, 60, DateTimeKind.Unspecified)) 330if (!IsValidTimeWithLeapSeconds(dt.Year, dt.Month, dt.Day, dt.Hour, dt.Minute, 60, DateTimeKind.Unspecified)) 365if (!IsValidTimeWithLeapSeconds(dt.Year, dt.Month, dt.Day, dt.Hour, dt.Minute, 60, kind))
system\datetimeoffset.cs (4)
114!DateTime.IsValidTimeWithLeapSeconds(m_dateTime.Year, m_dateTime.Month, m_dateTime.Day, m_dateTime.Hour, m_dateTime.Minute, 60, DateTimeKind.Utc)) 135!DateTime.IsValidTimeWithLeapSeconds(m_dateTime.Year, m_dateTime.Month, m_dateTime.Day, m_dateTime.Hour, m_dateTime.Minute, 60, DateTimeKind.Utc)) 157!DateTime.IsValidTimeWithLeapSeconds(m_dateTime.Year, m_dateTime.Month, m_dateTime.Day, m_dateTime.Hour, m_dateTime.Minute, 60, DateTimeKind.Utc)) 358return ClockDateTime.Year;
system\globalization\CalendricalCalculationsHelper.cs (1)
77return new DateTime(Math.Min((long)(Math.Floor(numberOfDays) * GregorianCalendar.TicksPerDay), DateTime.MaxValue.Ticks)).Year;
system\globalization\gregoriancalendar.cs (1)
458return time.Year;
system\security\cryptography\x509certificates\x509certificate.cs (1)
460if (!culture.DateTimeFormat.Calendar.IsValidDay(date.Year, date.Month, date.Day, 0)) {
system\timezone.cs (1)
127return (IsDaylightSavingTime(time, GetDaylightChanges(time.Year)));
system\timezoneinfo.cs (37)
350DaylightTimeStruct daylightTime = GetDaylightTime(adjustedTime.Year, rule); 398DaylightTimeStruct daylightTime = GetDaylightTime(adjustedTime.Year, rule); 528DaylightTimeStruct daylightTime = GetDaylightTime(adjustedTime.Year, rule); 606DaylightTimeStruct daylightTime = GetDaylightTime(adjustedTime.Year, rule); 630DaylightTimeStruct daylightTime = GetDaylightTime(dateTime.Year, rule); 785DaylightTimeStruct sourceDaylightTime = GetDaylightTime(dateTime.Year, sourceRule); 1489startTime = rule.IsStartDateMarkerForBeginningOfYear() ? new DateTime(daylightTime.Start.Year, 1, 1, 0, 0, 0) : daylightTime.Start + daylightTime.Delta; 1490endTime = rule.IsEndDateMarkerForEndOfYear() ? new DateTime(daylightTime.End.Year + 1, 1, 1, 0, 0, 0).AddTicks(-1) : daylightTime.End; 1511startTime = rule.IsStartDateMarkerForBeginningOfYear() ? new DateTime(daylightTime.Start.Year, 1, 1, 0, 0, 0) : daylightTime.Start + (invalidAtStart ? rule.DaylightDelta : TimeSpan.Zero); /* FUTURE: - rule.StandardDelta; */ 1512endTime = rule.IsEndDateMarkerForEndOfYear() ? new DateTime(daylightTime.End.Year + 1, 1, 1, 0, 0, 0).AddTicks(-1) : daylightTime.End + (invalidAtStart ? -rule.DaylightDelta : TimeSpan.Zero); 1562if (rule.IsStartDateMarkerForBeginningOfYear() && daylightTime.Start.Year > DateTime.MinValue.Year) { 1563AdjustmentRule previousYearRule = zone.GetAdjustmentRuleForTime(new DateTime(daylightTime.Start.Year - 1, 12, 31)); 1565DaylightTimeStruct previousDaylightTime = GetDaylightTime(daylightTime.Start.Year - 1, previousYearRule); 1569startTime = new DateTime(daylightTime.Start.Year, 1, 1, 0, 0, 0) - offset; 1576if (rule.IsEndDateMarkerForEndOfYear() && daylightTime.End.Year < DateTime.MaxValue.Year) { 1577AdjustmentRule nextYearRule = zone.GetAdjustmentRuleForTime(new DateTime(daylightTime.End.Year + 1, 1, 1)); 1580endTime = new DateTime(daylightTime.End.Year + 1, 12, 31) - utc - nextYearRule.BaseUtcOffsetDelta - nextYearRule.DaylightDelta; 1582DaylightTimeStruct nextdaylightTime = GetDaylightTime(daylightTime.End.Year + 1, nextYearRule); 1587endTime = new DateTime(daylightTime.End.Year + 1, 1, 1, 0, 0, 0).AddTicks(-1) - offset - rule.DaylightDelta; ; 1610if (!isAmbiguousLocalDst && ambiguousStart.Year != ambiguousEnd.Year) { 1643int startTimeYear = startTime.Year; 1644int endTimeYear = endTime.Year; 1650int timeYear = time.Year; 1708if (!isAmbiguous && startAmbiguousTime.Year != endAmbiguousTime.Year) { 1774if (!isInvalid && startInvalidTime.Year != endInvalidTime.Year) { 2000DaylightTimeStruct daylightTime = GetDaylightTime(time.Year, rule); 2033int timeYear = time.Year; 2074year = targetTime.Year; 3136m_dateStart.Year == m_dateEnd.Year; 3146m_dateStart.Year == m_dateEnd.Year;
PresentationFramework (38)
src\Framework\MS\Internal\AppModel\DeploymentExceptionMapper.cs (1)
259fwlink = String.Concat(fwlink, today.Year.ToString());
src\Framework\System\Windows\Controls\Calendar.cs (6)
734return new DateTime(DisplayDate.Year, 1, 1); 943newDate = DateTimeHelper.SetYear(this.DisplayDate, d.Year); 1386DateTime? selectedDate = new DateTime(this.DisplayDateInternal.Year, this.DisplayDateInternal.Month, 1); 1407DateTime selectedMonth = new DateTime(this.DisplayDate.Year, 12, 1); 1450DateTime? selectedDate = new DateTime(this.DisplayDateInternal.Year, this.DisplayDateInternal.Month, 1); 1457DateTime selectedMonth = new DateTime(this.DisplayDate.Year, 1, 1);
src\Framework\System\Windows\Controls\DatePicker.cs (4)
448if ((day.Month != dp.DisplayDate.Month || day.Year != dp.DisplayDate.Year) && !dp._calendar.DatePickerDisplayDateFlag) 1012int year = d.Year; 1027int year = discarded.Year;
src\Framework\System\Windows\Controls\DateTimeHelper.cs (8)
56return DateTimeHelper.AddYears(date, year - date.Year); 61DateTime? target = SetYear(date, yearMonth.Year); 77return ((dt1.Year - dt2.Year) * 12) + (dt1.Month - dt2.Month); 82return date.Year - (date.Year % 10); 87return new DateTime(d.Year, d.Month, 1, 0, 0, 0); 243result = date.Value.Year.ToString(format);
src\Framework\System\Windows\Controls\Primitives\CalendarItem.cs (19)
412if (date.Year == ((DateTime)b.DataContext).Year) 501((DateTime)child.DataContext).Year == selectedYear.Year) 512((DateTime)child.DataContext).Year == selectedYear.Year) 1052int daysInMonth = _calendar.GetDaysInMonth(firstDayOfMonth.Year, firstDayOfMonth.Month); 1254if (year <= DateTime.MaxValue.Year && year >= DateTime.MinValue.Year) 1264childButton.HasSelectedDays = (Owner.DisplayDate.Year == year); 1266if (year < this.Owner.DisplayDateStartInternal.Year || year > this.Owner.DisplayDateEndInternal.Year) 1301DateTime day = new DateTime(DisplayDate.Year, count + 1, 1); 1341_nextButton.IsEnabled = (this.Owner.DisplayDateEndInternal.Year != DisplayDate.Year); 1349_previousButton.IsEnabled = (this.Owner.DisplayDateStartInternal.Year != DisplayDate.Year); 1370_nextButton.IsEnabled = (this.Owner.DisplayDateEndInternal.Year > decadeEnd); 1378_previousButton.IsEnabled = (decade > this.Owner.DisplayDateStartInternal.Year);
System (2)
compmod\system\componentmodel\DateTimeConverter.cs (1)
143dt.Year, dt.Month, dt.Day, dt.Hour, dt.Minute, dt.Second, dt.Millisecond});
net\System\Net\mail\MailBnfHelper.cs (1)
271localBuilder.Append(value.Year);
System.Activities (1)
System\Activities\Expressions\Literal.cs (1)
118literalValue.Year,
System.Data (3)
fx\src\data\System\Data\Odbc\OdbcUtils.cs (1)
329unchecked((short)value.Year),
fx\src\data\System\Data\ProviderBase\DbBuffer.cs (2)
596unchecked((short)value.Year), 636unchecked((short)value.Year),
System.Data.Linq (4)
SqlClient\SqlMethods.cs (4)
21return endDate.Year - startDate.Year; 80return 12 * (endDate.Year - startDate.Year) + endDate.Month - startDate.Month;
System.Data.SqlXml (4)
System\Xml\Xsl\Runtime\XsltFunctions.cs (4)
318this.Year = (ushort)dateTime.Year; 441PrintYear( text, dt.Year); 445PrintYear(text, dt.Year); 515PrintYear(text, dt.Year);
System.Management (3)
ManagementDatetime.cs (3)
112 int year = DateTime.MinValue.Year; 283 string dmtfDateTime = date.Year.ToString(frmInt32).PadLeft(4,'0'); 294 DateTime dtTemp = new DateTime(date.Year ,date.Month,date.Day ,date.Hour ,date.Minute ,date.Second,0);
System.Runtime.Serialization (1)
System\Xml\XmlConverter.cs (1)
1082offset += ToCharsD4(value.Year, chars, offset);
System.ServiceModel (2)
System\ServiceModel\Channels\PeerUnsafeNativeCryptMethods.cs (1)
28wYear = (short)date.Year;
System\ServiceModel\Security\SecurityTimestamp.cs (1)
108ToChars(utcTime.Year, buffer, ref offset, 4);
System.ServiceModel.Web (1)
System\ServiceModel\Description\WebScriptClientGenerator.cs (1)
38this.serviceLastModified = new DateTime(this.serviceLastModified.Year, this.serviceLastModified.Month, this.serviceLastModified.Day, this.serviceLastModified.Hour, this.serviceLastModified.Minute, this.serviceLastModified.Second, DateTimeKind.Utc);
System.Web (3)
Security\SQLMembershipProvider.cs (1)
1895return new DateTime(utcDateTime.Year, utcDateTime.Month, utcDateTime.Day, utcDateTime.Hour, utcDateTime.Minute, utcDateTime.Second, DateTimeKind.Utc);
StaticFileHandler.cs (1)
512lastModifiedInUtc = new DateTime(fileInfo.LastWriteTimeUtc.Year,
UI\WebControls\basecomparevalidator.cs (1)
116int currentYear = DateTime.Today.Year;
System.Web.DataVisualization (24)
Common\DataManager\DataPoint.cs (2)
2129 ((DateTime)xValue).Year, 2297 yDate.Year,
Common\General\ChartAreaAxes.cs (2)
1973 monthsInteval += (date2.Year - date1.Year) * 12;
Common\General\ChartElement.cs (18)
987 DateTime sizeAdjustedDate = new DateTime(newStartDate.Year, 1, 1, 0, 0, 0); 1003 int year = (int)((int)(newStartDate.Year / intervalSize) * intervalSize); 1018 newStartDate = new DateTime(newStartDate.Year, 1028 newStartDate = new DateTime(newStartDate.Year, 1034 newStartDate = new DateTime(newStartDate.Year, 1040 newStartDate = new DateTime(newStartDate.Year, 1050 newStartDate = new DateTime(newStartDate.Year, 1061 newStartDate = new DateTime(newStartDate.Year, 1077 newStartDate = new DateTime(newStartDate.Year, 1202 roundedDateValue = new DateTime(dateValue.Year, 1207 roundedDateValue = new DateTime(dateValue.Year, 1212 roundedDateValue = new DateTime(dateValue.Year, 1217 roundedDateValue = new DateTime(dateValue.Year, 1223 roundedDateValue = new DateTime(dateValue.Year, 1232 roundedDateValue = new DateTime(dateValue.Year, 1242 roundedDateValue = new DateTime(dateValue.Year, 1316 if(date.Day == DateTime.DaysInMonth(date.Year, date.Month)) 1329 int daysInMobth = DateTime.DaysInMonth(date.Year, date.Month);
Common\General\DataManipulator.cs (2)
1625 if(dateTimeValue.Year >= rangeElements[index] && 1626 dateTimeValue.Year <= rangeElements[index+1])
System.Web.Extensions (1)
Script\Services\WebServiceClientProxyGenerator.cs (1)
29return new DateTime(writeTime.Year, writeTime.Month, writeTime.Day, writeTime.Hour, writeTime.Minute, writeTime.Second);
System.Windows.Forms (8)
winforms\Managed\System\WinForms\DateTimePicker.cs (4)
753if (maxSupportedDateTime.Year > MaxDateTime.Year) 813if (minSupportedDateTime.Year < 1753) 1713sys.wYear = (short)time.Year;
winforms\Managed\System\WinForms\MonthCalendar.cs (4)
1334int startYear = range.Start.Year; 1340int year = date.Year; 2707if (System.DateTime.Equals(calendar.SelectionStart.Year, calendar.SelectionEnd.Year)) {
System.Windows.Forms.DataVisualization (24)
Common\DataManager\DataPoint.cs (2)
2129 ((DateTime)xValue).Year, 2297 yDate.Year,
Common\General\ChartAreaAxes.cs (2)
1973 monthsInteval += (date2.Year - date1.Year) * 12;
Common\General\ChartElement.cs (18)
987 DateTime sizeAdjustedDate = new DateTime(newStartDate.Year, 1, 1, 0, 0, 0); 1003 int year = (int)((int)(newStartDate.Year / intervalSize) * intervalSize); 1018 newStartDate = new DateTime(newStartDate.Year, 1028 newStartDate = new DateTime(newStartDate.Year, 1034 newStartDate = new DateTime(newStartDate.Year, 1040 newStartDate = new DateTime(newStartDate.Year, 1050 newStartDate = new DateTime(newStartDate.Year, 1061 newStartDate = new DateTime(newStartDate.Year, 1077 newStartDate = new DateTime(newStartDate.Year, 1202 roundedDateValue = new DateTime(dateValue.Year, 1207 roundedDateValue = new DateTime(dateValue.Year, 1212 roundedDateValue = new DateTime(dateValue.Year, 1217 roundedDateValue = new DateTime(dateValue.Year, 1223 roundedDateValue = new DateTime(dateValue.Year, 1232 roundedDateValue = new DateTime(dateValue.Year, 1242 roundedDateValue = new DateTime(dateValue.Year, 1316 if(date.Day == DateTime.DaysInMonth(date.Year, date.Month)) 1329 int daysInMobth = DateTime.DaysInMonth(date.Year, date.Month);
Common\General\DataManipulator.cs (2)
1625 if(dateTimeValue.Year >= rangeElements[index] && 1626 dateTimeValue.Year <= rangeElements[index+1])
System.Workflow.Runtime (1)
Tracking\SqlTrackingService.cs (1)
2190return dateTime.Year.ToString(System.Globalization.CultureInfo.InvariantCulture) + PadToDblDigit(dateTime.Month) + PadToDblDigit(dateTime.Day) + " " + dateTime.Hour.ToString(System.Globalization.CultureInfo.InvariantCulture) + ":" + dateTime.Minute.ToString(System.Globalization.CultureInfo.InvariantCulture) + ":" + dateTime.Second.ToString(System.Globalization.CultureInfo.InvariantCulture) + ":" + dateTime.Millisecond.ToString(System.Globalization.CultureInfo.InvariantCulture);
System.Xml (10)
System\Xml\BinaryXml\SqlUtils.cs (3)
895WriteDate(sb, dt.Year, dt.Month, dt.Day); 902WriteDate(sb, dt.Year, dt.Month, dt.Day); 978return (int)(dt.Ticks - new DateTime(dt.Year, dt.Month, dt.Day, dt.Hour, dt.Minute, dt.Second).Ticks);
System\Xml\Schema\XsdDateTime.cs (6)
267get { return dt.Year; } 315get { return (int)(dt.Ticks - new DateTime(dt.Year, dt.Month, dt.Day, dt.Hour, dt.Minute, dt.Second).Ticks); } 382result = new DateTime(DateTime.Now.Year, xdt.Month, xdt.Day); 387TimeSpan addDiff = new DateTime(currentDateTime.Year, currentDateTime.Month, currentDateTime.Day) - new DateTime(xdt.Year, xdt.Month, xdt.Day); 439dt = new DateTime( DateTime.Now.Year, xdt.Month, xdt.Day ); 444TimeSpan addDiff = new DateTime(currentDateTime.Year, currentDateTime.Month, currentDateTime.Day) - new DateTime(xdt.Year, xdt.Month, xdt.Day);
System\Xml\Serialization\XmlCodeExporter.cs (1)
259ticks = (new DateTime(dt.Year, dt.Month, dt.Day)).Ticks;
UIAutomationClient (5)
System\Windows\Automation\RangeValuePattern.cs (5)
277return (double)((DateTime)propValue).Year; 326return (double)((DateTime)propValue).Year; 360return (double)((DateTime)propValue).Year; 398return (double)((DateTime)propValue).Year; 435return (double)((DateTime)propValue).Year;
WindowsBase (2)
Base\MS\Internal\IO\Zip\ZipIOBlockManager.cs (1)
504result |= (((UInt32)(dateTime.Year - 1980)) & 0x7F) << 25;
Base\MS\Internal\Security\RightsManagement\NativeRightsManagementAPIsStructures.cs (1)
60Year = (ushort)dateTime.Year;
WsatUI (1)
Configuration\ETWWsatTraceSession.cs (1)
203localtime.Year, localtime.Month, localtime.Day, localtime.Hour,