Version

DropDownButtonDisplayMode Property (XamDateTimeEditor)

Specifies when to display the drop down button. Default is MouseOver.
Syntax
'Declaration
 
Public Property DropDownButtonDisplayMode As DropDownButtonDisplayMode
public DropDownButtonDisplayMode DropDownButtonDisplayMode {get; set;}
Remarks

The DropDownButtonDisplayMode determines when the drop down button should be displayed.

Note that the drop down button will always be displayed when the editor is in edit mode. Therefore if the IsAlwaysInEditMode is true, this property will be ignored and the button will always be displayed.

Note that the default value of the property is MouseOver however styles of some of the themes may explicitly set this property to some other value to ensure consistency with the default operating system behavior. For example, the default XamComboEditor style in "Aero" theme used in Windows Vista sets this property to Always.

Example
The following example demonstrates handling the events that are invoked when the calendar dropdown is opened and closed.

For an overview of how to handle events in Visual Basic or Visual C#, see Event Handlers in Visual Basic and Visual C#. For specific information and code examples illustrating how to consume events in your application, see Consuming Events in the .NET Framework Developer's Guide.

Imports Infragistics.Windows.Editors

    Public Sub New()

        ' This call is required by the Windows Form Designer.
        InitializeComponent()

        ' Add any initialization after the InitializeComponent() call.

        Me.xamDateTimeEditor1.DropDownButtonDisplayMode = DropDownButtonDisplayMode.Always
    End Sub

    Private Sub xamDateTimeEditor1_DropDownOpened(ByVal sender As System.Object, ByVal e As System.Windows.RoutedEventArgs) Handles xamDateTimeEditor1.DropDownOpened

    End Sub

    Private Sub xamDateTimeEditor1_DropDownClosed(ByVal sender As System.Object, ByVal e As System.Windows.RoutedEventArgs) Handles xamDateTimeEditor1.DropDownClosed

    End Sub
using Infragistics.Windows.Editors;

        public Window1()
        {
            InitializeComponent();

            this.xamDateTimeEditor1.DropDownButtonDisplayMode = DropDownButtonDisplayMode.Always;
            this.xamDateTimeEditor1.DropDownOpened += new EventHandler<RoutedEventArgs>(this.xamDateTimeEditor1_DropDownOpened);
            this.xamDateTimeEditor1.DropDownClosed += new EventHandler<RoutedEventArgs>(this.xamDateTimeEditor1_DropDownClosed);
        }


        private void xamDateTimeEditor1_DropDownOpened(object sender, RoutedEventArgs e)
        {

        }

        private void xamDateTimeEditor1_DropDownClosed(object sender, RoutedEventArgs e)
        {

        }
        <igEditors:XamDateTimeEditor 
            
x:Name="xamDateTimeEditor1"
            
DropDownOpened="xamDateTimeEditor1_DropDownOpened" 
            
DropDownClosed="xamDateTimeEditor1_DropDownClosed"
            
DropDownButtonDisplayMode="Always" />
Requirements

Target Platforms: Windows 10, Windows 8.1, Windows 8, Windows 7, Windows Server 2012, 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

See Also