HypernovaDesktop Components · docs
Binarymission
WinFormsDate Picker › BinaryDatePicker

BinaryDatePicker

class.NET 6 / 8 / 10.NET Framework 4.8Binarymission.WinForms.Controls.DateTimeControls

BinaryDatePicker control is an Outlook© style DatePicker control, which lets a user select a date from its custom Month/Year calendar (a fixed-font calendar), and to display that date in a specified format. Apart from providing the look-and-feel of Microsoft© Outlook© DatePicker object, the control class has rich and powerful features and is highly configurable too.

public class BinaryDatePicker : Control

Inherits from / implements: Control

Remarks


The BinaryDatePicker control is an Outlook© style DatePicker control, which lets a user select a date from its custom Month/Year calendar, and to display that date in a specified format.
To change the look of the calendar portion of the control, use various calendar specific properties exposed by the control.
The control's CustomFormat property sets the date format for the control.
The default date format is set to the "Long" format as specified in your Operating system date/time settings. You can set a different Date format, by setting the CustomFormat property with a custom format string. For more details, please see the control's CustomFormat property.

Members at a glance

BinaryDatePickerClass constructor.
BackColorGets or sets the backcolor for the text control portion (date display) of the control.
BinaryCultureInfoGets or sets the CultureInfo to be used for the current instance of the control.
BorderColorGets or sets the border color for the control's date displaying control's borders.
CalendarForeColorGets or sets the color for the calendar's text forecolor (example - text forecolor for dates, days, etc.).
CalendarInactiveDateForeColorGets or sets the color for the Inactive date(s) in the calendar for a given month/year.
CalendarLegendDisplayGets or sets the legend display value, indicating whether or not the control should display in the calendar, a legend for various date markers.
CalendarMonthAndYearTrackerColorGets or sets the color for painting the Month/Year tracker control in the control's calendar.
CalendarMonthBackColorGets or sets the background color for the calendar.
CalendarMonthTitleForeColorGets or sets the color for the Month/Year title string in the Calendar.
CalenderDropDownArrowGlassRenderingColorGets or sets the color for drawing the dropdown arrow, when the UseDropDownImageStyle is set to DropDownImageStyle.GlassRendering.
CalenderDropDownGlassRenderingEndColorGets or sets the end color for drawing the dropdown button window, when the UseDropDownImageStyle is set to DropDownImageStyle.GlassRendering.
CalenderDropDownGlassRenderingStartColorGets or sets the start color for drawing the dropdown button window, when the UseDropDownImageStyle is set to DropDownImageStyle.GlassRendering.
CloseButtonBackColorGets or sets the BackColor property for the control's drop-down calendar's "Close" button.
CloseButtonFlatStyleGets or sets the FlatStyle property for the control's drop-down calendar's "Close" button.
CloseButtonForeColorGets or sets the ForeColor property for the control's drop-down calendar's "Close" button.
CloseButtonTextGets or sets the text to be associated with the drop-down calendar's command button, that is used to close the calendar window.
CustomDateXMLFeedGets or sets the path to an XML file containing the custom "named" date's name/value pair information.
CustomDropDownImageGets or sets the custom image that will be drawn in the control's drop-down button portion.
CustomFormatGets or sets the custom date format for displaying a date string in the control's text box, when the control's Format property is set to "Custom" (refer to BinaryDatePickerFormat for various available format values).
DisplayTextStateGets or sets the read-write/read-only state for the control's date display text box.
DotBorderDepthGets or sets the painting depth (length/width) of the dotted border for the control's date displaying control.
DotBorderGapGets or sets the painting gaps between the dots while drawing the dotted border for the control's date displaying control.
DrawBorderAsGets or sets the border state of the control when drawing the control's date displaying control's border.
DropWindowIsShowingWhether the calendar drop-down is currently on screen.
EditControlStyleIsExtendedGets or sets the control's text box border style.
EnableCustomDateXMLFeedGets or sets the value for enabling/disabling the XML based custom "named" dates facility.
FontGets or sets the Font value for the BinaryDatePicker control's text control.
ForeColorGets or sets the forecolor for the text control portion (date display) of the control.
FormatGets or sets the display format for the control.
HostedFromChildContainerWhether this picker is hosted inside another control rather than placed on a form directly. It is passed down to the calendar drop-down, which needs to know so it positions itself against the right window.
IsReadOnlyGets or sets a value indicating whether this instance is read-only.
MarkSelectedDateGets or sets the value indicating whether a selected date (including today's date) can be marked, in the calendar, with a filled circle.
MaxDateTimeSpecifies the maximum date value of the control.
MaxValueGets or sets the maximum date and time that can be selected in the control.
MinDateTimeSpecifies the minimum date value of the control.
MinValueGets or sets the minimum date and time that can be selected in the control.
NullDateStringGets or sets the string to be displayed when the control's DateTime value is set to "Null".
RenderDropDownButtonWithVisualStylesGets or sets whether to draw the calendar drop-down button using visual styles.
SelectionDateEllipseColorGets or sets the circle fill color for a given selected date in the calendar.
SelectionDateForeColorGets or sets the foreground color for a given selected date in the calendar.
ShowBorderAlwaysGets or sets whether the control will always have its border displayed, even when the control is not currently in focus.
ShowCustomMenuGets or sets whether the control's custom menu is displayed or not.
ShowDropDownCalendarWindowAfterAdjustingForVirtualAvaliableScreenSpaceGets or sets whether to adjust the display location of the drop-down calendar, when the BinaryDatePicker control is positioned in the form in such a location that when the container is run, there is no available space to display the drop-down calendar completely.
ShowPopupOnEnterGets or sets whether to display the calender popup window upon entering the control.
SpecialDatesGets or sets a special range of dates that will highlighted in the drop-down colander window, indicating they are special.
SpecialDatesFillColorGets or sets the Fill color for the special range of dates. Refer to SpecialDates property.
SpecialDatesForeColorGets or sets the fore color for drawing the date text of dates from the range of those defined special dates. Refer to SpecialDates property.
TodayButtonBackColorGets or sets the BackColor property for the control's drop-down calendar's "Today" button.
TodayButtonFlatStyleGets or sets the FlatStyle property for the control's drop-down calendar's "Today" button.
TodayButtonForeColorGets or sets the ForeColor property for the control's drop-down calendar's "Today" button.
TodayButtonTextGets or sets the text to be associated with the Calendar's command button, that is used to set the date to Today's date.
TodayCloseButtonsAreVisibleGets or sets whether the "Today" and "Close" buttons are visible when the control's drop-down calendar is displayed.
TodayEllipseColorGets or sets the circle fill color for "Today's" date, if it appears in the calendar.
TodayForeColorGets or sets the foreground color for the "today's" date, if it appears in the calendar.
UseDropDownImageStyleGets or sets the style to use, to draw the image in the control's drop-down button portion.
ValueGets or sets the date/time value assigned to the control.
ValueIsNullGets or sets whether the DateTime Value of the control is set to a "null" state value.
Dispose
OnEnterRaises the Enter event. BinaryDatePicker overrides it so the control's own handling runs alongside the base behavior.
OnFontChangedRaises the FontChanged event, passing the new font on to the calendar.
OnLeaveprotected method - not exposed!
OnMouseDownProtected method - not exposed!
OnMouseLeaveRaises the MouseLeave event. BinaryDatePicker overrides it so the control's own handling runs alongside the base behavior.
OnMouseMoveRaises the MouseMove event. BinaryDatePicker overrides it so the control's own handling runs alongside the base behavior.
OnMouseUpProtected method - not exposed!
OnPaintProtected method - not exposed!
OnResizeProtected method - not exposed!
OnSystemColorsChangedprotected event - not exposed!
SelectControlTextPerforms a "Select All" of the existing text in the control's text input area.
BinaryCalendarAboutToBeActivatedThis event is raised when the drop-down calendar is about to be displayed.
BinaryCalendarActivatedOccurs when the drop-down calendar is shown (activated for display).
BinaryCalendarDeactivatedOccurs when the drop-down calendar is deactivated (i.e. when the drop-down calendar is closed)
BinaryDateAboutToBeChangedThe event raised when the date value is about to be changed in the control.
BinaryDateChangedOccurs when the control's date/time value is changed.
CustomFormatDateChangedThe event raised when the date value is changed in the control when the Format is set to Custom.
MouseIsOverADateThis event is raised when the user points the mouse pointer over a date in the drop-down calander.
UserDateCustomValidatingAttach your custom validation handler to validate user typed date.

Constructors

BinaryDatePicker

public BinaryDatePicker()

Class constructor.

Constructs a new instance of BinaryDatePicker object.

Properties

BackColor

public override Color BackColor

Gets or sets the backcolor for the text control portion (date display) of the control.

Value. A Color value for the date displaying text control portion of the control.

Set this property to display the selected date with a specific text background Color.
Note:- Setting this property will not change the backcolor of the dropdown calendar of this control.
This property will only set the backcolor property of the text control portion of the control. The default Color value for this property is Window value.

BinaryCultureInfo

public CultureInfo BinaryCultureInfo

Gets or sets the CultureInfo to be used for the current instance of the control.

By default, the control uses the default culture (of the currently running thread) CurrentCulture to display date/time and its drop-down calendar. If for any reason, you want to specifically set the control's culture to use a different CultureInfo value (say you want to use "fr-FR" CultureInfo in a system with default CultureInfo pointing to "en-GB"), then you can set this property with that specific value, to let the control use that specific culture for its current instance.

BorderColor

public Color BorderColor

Gets or sets the border color for the control's date displaying control's borders.

Use this property to set the Control's border color. By default, this property is set to Highlight color value.
Note: This property is applicable only when the control is in the ExtendedStyle mode (Refer EditControlStyleIsExtended).

CalendarForeColor

public Color CalendarForeColor

Gets or sets the color for the calendar's text forecolor (example - text forecolor for dates, days, etc.).

Set this property to set the forecolor for the dates and day names, as they appear in the dropdown calendar.

CalendarInactiveDateForeColor

public Color CalendarInactiveDateForeColor

Gets or sets the color for the Inactive date(s) in the calendar for a given month/year.

Value. A Color value.

Inactive dates are those dates in a month calendar, that are displayed, but they do not belong to that month. These dates are shown just as a continuation, of the previous and/or next month's dates, in a given month's calendar. To differentiate these inactive dates form the current month's dates, you can set this property. By default, this property is set to ControlDark color value.

CalendarLegendDisplay

public bool CalendarLegendDisplay

Gets or sets the legend display value, indicating whether or not the control should display in the calendar, a legend for various date markers.

Value. A bool value indicating whether legend display facility is on or off.

The calendar has the facility to show a circle around a "selected date" and "today's date", with different fill colors (which is again configurable). To explain the user what these filled circles mean, a simple legend is displayed at the bottom of the calendar. To switch off this legend display, set this property to false. By default, the property is assigned a true value.

CalendarMonthAndYearTrackerColor

public Color CalendarMonthAndYearTrackerColor

Gets or sets the color for painting the Month/Year tracker control in the control's calendar.

Value. A Color value.

BinaryDatePicker's calendar control has a title which displays a given month name and year, as currently displayed in the calendar. The title area also carries two tracking controls (displayed as small tilted triangles) to the extreme left and right ends of the title. A user can click these controls to navigate between various month(s) and year(s). BinaryDatePicker control allows you to customise these tracking control's forecolors, by allowing you to set the CalendarMonthAndYearTrackerColor property.

CalendarMonthBackColor

public Color CalendarMonthBackColor

Gets or sets the background color for the calendar.

CalendarMonthTitleForeColor

public Color CalendarMonthTitleForeColor

Gets or sets the color for the Month/Year title string in the Calendar.

CalenderDropDownArrowGlassRenderingColor

public Color CalenderDropDownArrowGlassRenderingColor

Gets or sets the color for drawing the dropdown arrow, when the UseDropDownImageStyle is set to DropDownImageStyle.GlassRendering.

CalenderDropDownGlassRenderingEndColor

public Color CalenderDropDownGlassRenderingEndColor

Gets or sets the end color for drawing the dropdown button window, when the UseDropDownImageStyle is set to DropDownImageStyle.GlassRendering.

CalenderDropDownGlassRenderingStartColor

public Color CalenderDropDownGlassRenderingStartColor

Gets or sets the start color for drawing the dropdown button window, when the UseDropDownImageStyle is set to DropDownImageStyle.GlassRendering.

CloseButtonBackColor

public Color CloseButtonBackColor

Gets or sets the BackColor property for the control's drop-down calendar's "Close" button.

CloseButtonFlatStyle

public FlatStyle CloseButtonFlatStyle

Gets or sets the FlatStyle property for the control's drop-down calendar's "Close" button.

CloseButtonForeColor

public Color CloseButtonForeColor

Gets or sets the ForeColor property for the control's drop-down calendar's "Close" button.

CloseButtonText

public string CloseButtonText

Gets or sets the text to be associated with the drop-down calendar's command button, that is used to close the calendar window.

The control's drop-down calendar displays a command button to let the user conveniently close the calendar window.
By default, this command button has the text "Close" in English language.
If you want to change this text to display "Close" in another language convenient to your user, then you can set this property with a string pointing to another language equivalent of the english word "Close".
Note: The command button size is a fixed size of Size(47,20).
Hence ensure the new text you will be assigning to this property is within this size range, to display the text properly.

CustomDateXMLFeed

public string CustomDateXMLFeed

Gets or sets the path to an XML file containing the custom "named" date's name/value pair information.

Value. The location of an XML file containing the custom date names and values. The default value is Empty.

This property extends the BinaryDatePicker control by adding the capability to let you type in a custom "named" date string as specified in the XML file. For example, if you set a date name called "Customer day" and set its date to "03/03/2003" in the XML file (in the expected format) and set this property to point to that XML file, your users can type in "Customer day" in the BinaryDatePicker control text box and the appropriate date, i.e. 03/03/2003, will be displayed in the control's text box and the control's Value property will be set to this date value accordingly.
NOTE : Remember, the XML date data (i.e. the dates you will define in the XML document) will be parsed based on the Current culture of the thread.
But if you have specified any specific CultureInfo, by setting the BinaryCultureInfo property, then the dates specified in the XML file will be parsed based on that specified CultureInfo.
The required format of the XML file is described below.
You can cut and paste the below XML format and save the content as an XML file, for example, as CustomDates.xml (as is used in the demonstration program), and then you can change the contents of the file with your own custom dates and values.

The following XML content illustrates the expected XML file format :- <?xml version="1.0" encoding="utf-8" ?> <CustomDates> <DateLookup> <DateName>Corporate day</DateName> <DateValue>14/03/2003</DateValue> </DateLookup> <DateLookup> <DateName>Shareholder's day</DateName> <DateValue>16/03/2003</DateValue> </DateLookup> <DateLookup> <DateName>Agenda date</DateName> <DateValue>15/03/2003</DateValue> </DateLookup> <DateLookup> <DateName>Settlement date</DateName> <DateValue>25/11/2003</DateValue> </DateLookup> <DateLookup> <DateName>Customer day</DateName> <DateValue>03/03/2003</DateValue> </DateLookup> <DateLookup> <DateName>Project release day</DateName> <DateValue>21/03/2003</DateValue> </DateLookup> </CustomDates> <HighlightDates> <Date>18/09/2007</Date> <Date>17/09/2007</Date> <Date>14/09/2007</Date> <Date>15/09/2007</Date> </HighlightDates>

CustomDropDownImage

public Bitmap CustomDropDownImage

Gets or sets the custom image that will be drawn in the control's drop-down button portion.

BinaryDatePicker control lets you set a custom image to be used to draw the control's drop-down button portion. When you want to use your own custom image, first set the property UseDropDownImageStyle to DropDownImageStyle.CustomImage and then set this property to an image of size 11 x 13 (width 11, height 13).
Note: If your specified image is not of size 11 x 13, then the built-in calendar image will be used to draw instead.

CustomFormat

public string CustomFormat

Gets or sets the custom date format for displaying a date string in the control's text box, when the control's Format property is set to "Custom" (refer to BinaryDatePickerFormat for various available format values).

Value. A string that represents the custom date-time format.

Refer to DateTimeFormatInfo type to specify a valid "custom" date pattern string to set this property. For example, to display the date as "March 27 2001 at 12 AM", set the CustomFormat property to "MMMM dd yyyy 'at' hh tt". By default, this property is set to the "Long" date/time format as per the culture of the current thread.

DisplayTextState

public bool DisplayTextState

Gets or sets the read-write/read-only state for the control's date display text box.

Set this property to true/false, depending on whether you want to Enable/Disable (i.e. read-write/read-only) the BinaryDatePicker control's date display text box.

DotBorderDepth

public int DotBorderDepth

Gets or sets the painting depth (length/width) of the dotted border for the control's date displaying control.

When you set the DrawBorderAs property to "Dotted" (refer BorderState), the control is drawn with a dotted border.
You can set the depth of each of the dotted border part, by setting this property. This property determines the length/width of each of the dot, while drawing the border.
By default, this property is set to integer (int) value of 4.

DotBorderGap

public int DotBorderGap

Gets or sets the painting gaps between the dots while drawing the dotted border for the control's date displaying control.

When you set the DrawBorderAs property to "Dotted" (refer BorderState), the control is drawn with a dotted border.
You can set the gap between each of the dotted border part by setting this property. This property determines the length of gap between each dot, while drawing the border.
By default, this property is set to integer (int) value of 5.

DrawBorderAs

public BorderState DrawBorderAs

Gets or sets the border state of the control when drawing the control's date displaying control's border.

This property is available only when the control is in EditControlStyleIsExtended mode.
Basically, there are two different states available for drawing the control's border, while in EditControlStyleIsExtended.
  1. Normal border - This is a BorderState when the control's border is drawn using a continuous line.
  2. Dotted border - This is a BorderState when the control's border is drawn as a dotted border.

If you want the control's border to be drawn as a dotted border, you should set this property to the appropriate value, viz., "BinaryDatePicker.BorderState.Dotted".
If you want the control's border to be drawn as a regular un-dotted line, set this property to "BinaryDatePicker.BorderState.Normal".

DropWindowIsShowing

public bool DropWindowIsShowing

Whether the calendar drop-down is currently on screen.

EditControlStyleIsExtended

public bool EditControlStyleIsExtended

Gets or sets the control's text box border style.

BinaryDatePicker control supports two styles for its date displaying text box control.
One is the standard Windows text box style and the other is a text box with the Windows© XP© style text box borders.
Also, when you set the property to true, the control additionally supports a hovering mechanism for the text box, i.e., when the mouse pointer is brought into the text box area, the borders change to the XP style borders, and when the text box loses input focus, the borders change to a different state indicating that the control has lost focus.
This is similar to the behaviour that you can see in the MSDN© edit/combo controls.
When you set this property to true, please note that, by default DrawBorderAs property is set to "BinaryDatePicker.BorderState.Normal". By default, this property is set to false.

EnableCustomDateXMLFeed

public bool EnableCustomDateXMLFeed

Gets or sets the value for enabling/disabling the XML based custom "named" dates facility.

You will have to set this property to true if you want use the CustomDateXMLFeed facility. By default, this property is set to false.

Font

public override Font Font

Gets or sets the Font value for the BinaryDatePicker control's text control.

ForeColor

public override Color ForeColor

Gets or sets the forecolor for the text control portion (date display) of the control.

Value. A Color value for the date displaying text control portion of the control.

Set this property in order to display the selected date, in a specific Color.
Note:- Setting this property will not change the forecolor of the dropdown calendar of this control. This property will only set the forecolor property of the text control portion of the control. The default Color value for this property is WindowText value.

Format

public BinaryDatePickerFormat Format

Gets or sets the display format for the control.

Value. A BinaryDatePickerFormat enum.

Refer to BinaryDatePickerFormat enum to specify a valid date/time display format. For example, if you set this property to "Long", the date will displayed using the Long date format as specified in your computer's Operating system.

HostedFromChildContainer

public bool HostedFromChildContainer

Whether this picker is hosted inside another control rather than placed on a form directly. It is passed down to the calendar drop-down, which needs to know so it positions itself against the right window.

IsReadOnly

public bool IsReadOnly

Gets or sets a value indicating whether this instance is read-only.

MarkSelectedDate

public bool MarkSelectedDate

Gets or sets the value indicating whether a selected date (including today's date) can be marked, in the calendar, with a filled circle.

The default value is true, meaning, that any selected date in the calendar (including Today's date) will be marked with a filled circle.
Note: When this value to set to false, the control's another property CalendarLegendDisplay is also set to false automatically.
Remember this when setting this property to false.

MaxDateTime

public DateTime MaxDateTime

Specifies the maximum date value of the control.

Value. The maximum date is set to 31/12/9999 00:00:00.

MaxValue

public DateTime MaxValue

Gets or sets the maximum date and time that can be selected in the control.

Value. The maximum date and time that can be selected in the control. The default is 31/12/9999 00:00:00.

MinDateTime

public DateTime MinDateTime

Specifies the minimum date value of the control.

Value. The minimum date is set to 1/2/0001 00:00:00.

MinValue

public DateTime MinValue

Gets or sets the minimum date and time that can be selected in the control.

Value. The minimum date and time that can be selected in the control. The default is 1/2/0001 00:00:00.

NullDateString

public string NullDateString

Gets or sets the string to be displayed when the control's DateTime value is set to "Null".

Value. A string value.

When the control's DateTime value is set to "null" or DBNull or when the user clears the date displaying text control to blank (i.e he is setting the control's DateTime value to null), the textbox portion of the control will display a text string representing the Null state. This "Null date" representing string is the value of this property.
By default, this property is set to Empty.
You can override this text string and set your own string, based on your own needs or convenience.
Say, for example, you may like to set it to "No date selected!". To achieve this, set this property with an appropriate string value.

RenderDropDownButtonWithVisualStyles

public bool RenderDropDownButtonWithVisualStyles

Gets or sets whether to draw the calendar drop-down button using visual styles.

SelectionDateEllipseColor

public Color SelectionDateEllipseColor

Gets or sets the circle fill color for a given selected date in the calendar.

When a user selects a date from the dropdown calendar, a special circle/ellipse is drawn around that date (with a default color "Blue") to mark the selected date. You can change this and set a special color to that circle that is drawn around the date. To achieve this, set this property to a Color value. By default, this property is set to Blue.

SelectionDateForeColor

public Color SelectionDateForeColor

Gets or sets the foreground color for a given selected date in the calendar.

When a user selects a date from the dropdown calendar, a special color can be used as the forecolor for that date, so as to mark the user's selection. To achieve this, set this property to a Color value. By default, this property is set to Yellow.

ShowBorderAlways

public bool ShowBorderAlways

Gets or sets whether the control will always have its border displayed, even when the control is not currently in focus.

If set to true, the control will always display its border even when the input focus is not on the control. By default, this property is set to false.
Note: This property has effect only when the control is in extended mode (refer EditControlStyleIsExtended).

ShowCustomMenu

public bool ShowCustomMenu

Gets or sets whether the control's custom menu is displayed or not.

BinaryDatePicker control provides a custom menu to let the user select and set some of the common dates like today, tomorrow, next week,etc. If you wish not to have this custom menu, then you can set this property to false, in which case the default custom menu for the Windows Edit control will be displayed when the user right clicks on the control's edit control. By default, this property is set to true.

ShowDropDownCalendarWindowAfterAdjustingForVirtualAvaliableScreenSpace

public bool ShowDropDownCalendarWindowAfterAdjustingForVirtualAvaliableScreenSpace

Gets or sets whether to adjust the display location of the drop-down calendar, when the BinaryDatePicker control is positioned in the form in such a location that when the container is run, there is no available space to display the drop-down calendar completely.

ShowPopupOnEnter

public bool ShowPopupOnEnter

Gets or sets whether to display the calender popup window upon entering the control.

SpecialDates

public DateTime[] SpecialDates

Gets or sets a special range of dates that will highlighted in the drop-down colander window, indicating they are special.

SpecialDatesFillColor

public Color SpecialDatesFillColor

Gets or sets the Fill color for the special range of dates. Refer to SpecialDates property.

SpecialDatesForeColor

public Color SpecialDatesForeColor

Gets or sets the fore color for drawing the date text of dates from the range of those defined special dates. Refer to SpecialDates property.

TodayButtonBackColor

public Color TodayButtonBackColor

Gets or sets the BackColor property for the control's drop-down calendar's "Today" button.

TodayButtonFlatStyle

public FlatStyle TodayButtonFlatStyle

Gets or sets the FlatStyle property for the control's drop-down calendar's "Today" button.

TodayButtonForeColor

public Color TodayButtonForeColor

Gets or sets the ForeColor property for the control's drop-down calendar's "Today" button.

TodayButtonText

public string TodayButtonText

Gets or sets the text to be associated with the Calendar's command button, that is used to set the date to Today's date.

The control's drop-down calendar displays a command button to let the user conveniently set the control's date to DateTime.Today (or DateTime.Now).
By default, this command button has the text "Today" in English language.
If you want to change this text to display "Today" in another language convenient to your user, then you can set this property with a string pointing to another language equivalent of the english word "Today".
Note: The command button size is a fixed size of Size(47,20).
Hence ensure the new text you will be assigning to this property is within this size range, to display the text properly.

TodayCloseButtonsAreVisible

public bool TodayCloseButtonsAreVisible

Gets or sets whether the "Today" and "Close" buttons are visible when the control's drop-down calendar is displayed.

TodayEllipseColor

public Color TodayEllipseColor

Gets or sets the circle fill color for "Today's" date, if it appears in the calendar.

When a user selects "Today's" date from the dropdown calendar, a special circle/ellipse is drawn around that date (with a default color Green) to mark the selected date. You can change this and set a special color to that circle that is drawn around the date. To achieve this, set this property to a Color value.

TodayForeColor

public Color TodayForeColor

Gets or sets the foreground color for the "today's" date, if it appears in the calendar.

When a user selects "Today's" date from the dropdown calendar, a special color can be used as the forecolor for that date, so as to mark the user's selection. To achieve this, set this property to a Color value. By default, this property is set to Yellow.

UseDropDownImageStyle

public DropDownImageStyle UseDropDownImageStyle

Gets or sets the style to use, to draw the image in the control's drop-down button portion.

Please refer to the property CustomDropDownImage for more details.

Value

public object Value

Gets or sets the date/time value assigned to the control.

If the Value property has not been changed, either in the code or by the user, it is set to the current date/time value <see cref="DateTime.Now"></see>.
Note: When the current value of this property is null or DBNull, this property returns the value of the NullDateString property.
Also note that the property is of type Object and hence whenever you set or get this property, please remember to explicitly cast it to the relevant type i.e., Object or DateTime respectively.

ValueIsNull

public bool ValueIsNull

Gets or sets whether the DateTime Value of the control is set to a "null" state value.

Methods

Dispose

protected override void Dispose(bool disposing)

No summary in the source yet.

disposing

OnEnter

protected override void OnEnter(EventArgs e)

Raises the Enter event. BinaryDatePicker overrides it so the control's own handling runs alongside the base behavior.

e
The data for the event.

OnFontChanged

protected override void OnFontChanged(EventArgs e)

Raises the FontChanged event, passing the new font on to the calendar.

e
The data for the event.

OnLeave

protected override void OnLeave(EventArgs e)

protected method - not exposed!

e

OnMouseDown

protected override void OnMouseDown(MouseEventArgs e)

Protected method - not exposed!

e

OnMouseLeave

protected override void OnMouseLeave(EventArgs e)

Raises the MouseLeave event. BinaryDatePicker overrides it so the control's own handling runs alongside the base behavior.

e
The data for the event.

OnMouseMove

protected override void OnMouseMove(MouseEventArgs e)

Raises the MouseMove event. BinaryDatePicker overrides it so the control's own handling runs alongside the base behavior.

e
The data for the event.

OnMouseUp

protected override void OnMouseUp(MouseEventArgs e)

Protected method - not exposed!

e

OnPaint

protected override void OnPaint(PaintEventArgs e)

Protected method - not exposed!

e

OnResize

protected override void OnResize(EventArgs e)

Protected method - not exposed!

e

OnSystemColorsChanged

protected override void OnSystemColorsChanged(EventArgs e)

protected event - not exposed!

e

SelectControlText

public void SelectControlText()

Performs a "Select All" of the existing text in the control's text input area.

Events

BinaryCalendarAboutToBeActivated

public event EventHandler BinaryCalendarAboutToBeActivated

This event is raised when the drop-down calendar is about to be displayed.

Note that the drop-down calendar is displayed in modeless state. This means that if the form instance (that is hosting this date picker control instance) is set with its TopMost property set to true, you will need to reset your form instance's TopMost property to false from the time the drop-down calendar is displayed, and until the calendar is closed/deactivated.

To ensure this is correctly automated, you are advised to subscribe this event BinaryCalendarAboutToBeActivated, and in this event's handler, set the hosting Forms's TOpMost property to false.

Once the calendar is closed, you can re-set your hosting form instance's TopMost property to true again, by setting that property to true, in this control's BinaryCalendarDeactivated event.

BinaryCalendarActivated

public event EventHandler BinaryCalendarActivated

Occurs when the drop-down calendar is shown (activated for display).

This event is fired when the user clicks the drop-down button of the control and the calendar is displayed/activated for display.

BinaryCalendarDeactivated

public event EventHandler BinaryCalendarDeactivated

Occurs when the drop-down calendar is deactivated (i.e. when the drop-down calendar is closed)

This event is fired when the calendar is deactivated/closed.

BinaryDateAboutToBeChanged

public event DateChangePreHandler BinaryDateAboutToBeChanged

The event raised when the date value is about to be changed in the control.

BinaryDateChanged

public event EventHandler BinaryDateChanged

Occurs when the control's date/time value is changed.

This event is fired whenever the Value property gets changed to a valid DateTime value
(i.e. either when a date is selected from the dropdown month/year Calendar or when the Value property is specificially changed).

CustomFormatDateChanged

public event CustomFormatDateChangeHandler CustomFormatDateChanged

The event raised when the date value is changed in the control when the Format is set to Custom.

This event is raised only when the user has set the date value and leaves the control.

MouseIsOverADate

public event MouseOverADateHandler MouseIsOverADate

This event is raised when the user points the mouse pointer over a date in the drop-down calander.

UserDateCustomValidating

public event CustomValidator UserDateCustomValidating

Attach your custom validation handler to validate user typed date.