Why is DateTimePicker MaxDateTime 12/31/9998 23:59:59?

http://msdn.microsoft.com/en-us/library/system.windows.forms.datetimepicker.maxdate.aspx http://msdn.microsoft.com/en-us/library/system.windows.forms.datetimepicker .maxdatetime.aspx

This value seems arbitrary if no explanation is provided. Why is this not just DateTime.MaxValue?

+6
source share
1 answer

This is probably not a business reason. I do not think it is a coincidence that the value is exactly one year before DateTime.MaxValue . DateTimePicker may have some internal logic that breaks pages into neighboring months that break near DateTime.MaxValue , which did not cost a special case.

+1
source

Source: https://habr.com/ru/post/899796/