Intersoft ClientUI Documentation
UXMenuItem Class
Members  See Also  Send Feedback
Intersoft.Client.UI.Aqua Namespace : UXMenuItem Class






Represents menu item control.

Object Model

UXMenuItem Class

Syntax

Visual Basic (Declaration) 
<TemplateVisualStateAttribute(Name="MouseOver", GroupName="CommonStates")>
<TemplateVisualStateAttribute(GroupName="CommonStates", Name="Disabled")>
<DoNotObfuscateTypeAttribute()>
<TemplatePartAttribute(Name="TextCommandElement", Type=System.Windows.Controls.TextBlock)>
<DescriptionAttribute("Represents menu item control.")>
<TemplateVisualStateAttribute(GroupName="CommonStates", Name="Normal")>
<StyleTypedPropertyAttribute(Property="ItemContainerStyle", StyleTargetType=Intersoft.Client.UI.Aqua.UXMenuItem)>
<TemplateVisualStateAttribute(GroupName="SelectionStates", Name="Unselected")>
<TemplatePartAttribute(Name="RootElement", Type=System.Windows.Controls.Grid)>
<TemplateVisualStateAttribute(GroupName="SelectionStates", Name="Selected")>
<TemplateVisualStateAttribute(GroupName="CommonStates", Name="Checked")>
<TemplatePartAttribute(Name="IndicatorImageElement", Type=System.Windows.Controls.Image)>
<TemplatePartAttribute(Name="AnimationElement", Type=System.Windows.Controls.Border)>
<TemplatePartAttribute(Name="ContentPresenter", Type=System.Windows.Controls.ContentPresenter)>
<TemplatePartAttribute(Name="ContentElement", Type=System.Windows.Controls.Grid)>
<TemplatePartAttribute(Name="MenuElement", Type=Intersoft.Client.UI.Aqua.UXMenu)>
<TemplatePartAttribute(Name="PointerElement", Type=System.Windows.Shapes.Path)>
<TemplatePartAttribute(Name="ItemsPresenter", Type=System.Windows.Controls.ItemsPresenter)>
<TemplatePartAttribute(Name="IndicatorElement", Type=System.Windows.Controls.Border)>
<TemplatePartAttribute(Name="IndicatorTemplateElement", Type=System.Windows.Controls.ContentControl)>
Public Class UXMenuItem 
   Inherits Intersoft.Client.Framework.ISHeaderedSelectionControl
   Implements IControlIFramework, ILicensing, INavigationSourceINavigationSupportICommandSourceISelectionISelectionItem 
Visual Basic (Usage)Copy Code
Dim instance As UXMenuItem
C# 
[TemplateVisualStateAttribute(Name="MouseOver", GroupName="CommonStates")]
[TemplateVisualStateAttribute(GroupName="CommonStates", Name="Disabled")]
[DoNotObfuscateTypeAttribute()]
[TemplatePartAttribute(Name="TextCommandElement", Type=System.Windows.Controls.TextBlock)]
[DescriptionAttribute("Represents menu item control.")]
[TemplateVisualStateAttribute(GroupName="CommonStates", Name="Normal")]
[StyleTypedPropertyAttribute(Property="ItemContainerStyle", StyleTargetType=Intersoft.Client.UI.Aqua.UXMenuItem)]
[TemplateVisualStateAttribute(GroupName="SelectionStates", Name="Unselected")]
[TemplatePartAttribute(Name="RootElement", Type=System.Windows.Controls.Grid)]
[TemplateVisualStateAttribute(GroupName="SelectionStates", Name="Selected")]
[TemplateVisualStateAttribute(GroupName="CommonStates", Name="Checked")]
[TemplatePartAttribute(Name="IndicatorImageElement", Type=System.Windows.Controls.Image)]
[TemplatePartAttribute(Name="AnimationElement", Type=System.Windows.Controls.Border)]
[TemplatePartAttribute(Name="ContentPresenter", Type=System.Windows.Controls.ContentPresenter)]
[TemplatePartAttribute(Name="ContentElement", Type=System.Windows.Controls.Grid)]
[TemplatePartAttribute(Name="MenuElement", Type=Intersoft.Client.UI.Aqua.UXMenu)]
[TemplatePartAttribute(Name="PointerElement", Type=System.Windows.Shapes.Path)]
[TemplatePartAttribute(Name="ItemsPresenter", Type=System.Windows.Controls.ItemsPresenter)]
[TemplatePartAttribute(Name="IndicatorElement", Type=System.Windows.Controls.Border)]
[TemplatePartAttribute(Name="IndicatorTemplateElement", Type=System.Windows.Controls.ContentControl)]
public class UXMenuItem : Intersoft.Client.Framework.ISHeaderedSelectionControl, IControlIFramework, ILicensing, INavigationSourceINavigationSupportICommandSourceISelectionISelectionItem  
JScript 
TemplateVisualStateAttribute(Name="MouseOver", GroupName="CommonStates")
TemplateVisualStateAttribute(GroupName="CommonStates", Name="Disabled")
DoNotObfuscateTypeAttribute()
TemplatePartAttribute(Name="TextCommandElement", Type=System.Windows.Controls.TextBlock)
DescriptionAttribute("Represents menu item control.")
TemplateVisualStateAttribute(GroupName="CommonStates", Name="Normal")
StyleTypedPropertyAttribute(Property="ItemContainerStyle", StyleTargetType=Intersoft.Client.UI.Aqua.UXMenuItem)
TemplateVisualStateAttribute(GroupName="SelectionStates", Name="Unselected")
TemplatePartAttribute(Name="RootElement", Type=System.Windows.Controls.Grid)
TemplateVisualStateAttribute(GroupName="SelectionStates", Name="Selected")
TemplateVisualStateAttribute(GroupName="CommonStates", Name="Checked")
TemplatePartAttribute(Name="IndicatorImageElement", Type=System.Windows.Controls.Image)
TemplatePartAttribute(Name="AnimationElement", Type=System.Windows.Controls.Border)
TemplatePartAttribute(Name="ContentPresenter", Type=System.Windows.Controls.ContentPresenter)
TemplatePartAttribute(Name="ContentElement", Type=System.Windows.Controls.Grid)
TemplatePartAttribute(Name="MenuElement", Type=Intersoft.Client.UI.Aqua.UXMenu)
TemplatePartAttribute(Name="PointerElement", Type=System.Windows.Shapes.Path)
TemplatePartAttribute(Name="ItemsPresenter", Type=System.Windows.Controls.ItemsPresenter)
TemplatePartAttribute(Name="IndicatorElement", Type=System.Windows.Controls.Border)
TemplatePartAttribute(Name="IndicatorTemplateElement", Type=System.Windows.Controls.ContentControl)
public class UXMenuItem extends Intersoft.Client.Framework.ISHeaderedSelectionControl implements IControlIFramework, ILicensing, INavigationSourceINavigationSupportICommandSourceISelectionISelectionItem 
Managed Extensions for C++ 
[TemplateVisualStateAttribute(Name="MouseOver", GroupName="CommonStates")]
[TemplateVisualStateAttribute(GroupName="CommonStates", Name="Disabled")]
[DoNotObfuscateTypeAttribute()]
[TemplatePartAttribute(Name="TextCommandElement", Type=System.Windows.Controls.TextBlock)]
[DescriptionAttribute("Represents menu item control.")]
[TemplateVisualStateAttribute(GroupName="CommonStates", Name="Normal")]
[StyleTypedPropertyAttribute(Property="ItemContainerStyle", StyleTargetType=Intersoft.Client.UI.Aqua.UXMenuItem)]
[TemplateVisualStateAttribute(GroupName="SelectionStates", Name="Unselected")]
[TemplatePartAttribute(Name="RootElement", Type=System.Windows.Controls.Grid)]
[TemplateVisualStateAttribute(GroupName="SelectionStates", Name="Selected")]
[TemplateVisualStateAttribute(GroupName="CommonStates", Name="Checked")]
[TemplatePartAttribute(Name="IndicatorImageElement", Type=System.Windows.Controls.Image)]
[TemplatePartAttribute(Name="AnimationElement", Type=System.Windows.Controls.Border)]
[TemplatePartAttribute(Name="ContentPresenter", Type=System.Windows.Controls.ContentPresenter)]
[TemplatePartAttribute(Name="ContentElement", Type=System.Windows.Controls.Grid)]
[TemplatePartAttribute(Name="MenuElement", Type=Intersoft.Client.UI.Aqua.UXMenu)]
[TemplatePartAttribute(Name="PointerElement", Type=System.Windows.Shapes.Path)]
[TemplatePartAttribute(Name="ItemsPresenter", Type=System.Windows.Controls.ItemsPresenter)]
[TemplatePartAttribute(Name="IndicatorElement", Type=System.Windows.Controls.Border)]
[TemplatePartAttribute(Name="IndicatorTemplateElement", Type=System.Windows.Controls.ContentControl)]
public __gc class UXMenuItem : public Intersoft.Client.Framework.ISHeaderedSelectionControl, IControlIFramework, ILicensing, INavigationSourceINavigationSupportICommandSourceISelectionISelectionItem  
C++/CLI 
[TemplateVisualStateAttribute(Name="MouseOver", GroupName="CommonStates")]
[TemplateVisualStateAttribute(GroupName="CommonStates", Name="Disabled")]
[DoNotObfuscateTypeAttribute()]
[TemplatePartAttribute(Name="TextCommandElement", Type=System.Windows.Controls.TextBlock)]
[DescriptionAttribute("Represents menu item control.")]
[TemplateVisualStateAttribute(GroupName="CommonStates", Name="Normal")]
[StyleTypedPropertyAttribute(Property="ItemContainerStyle", StyleTargetType=Intersoft.Client.UI.Aqua.UXMenuItem)]
[TemplateVisualStateAttribute(GroupName="SelectionStates", Name="Unselected")]
[TemplatePartAttribute(Name="RootElement", Type=System.Windows.Controls.Grid)]
[TemplateVisualStateAttribute(GroupName="SelectionStates", Name="Selected")]
[TemplateVisualStateAttribute(GroupName="CommonStates", Name="Checked")]
[TemplatePartAttribute(Name="IndicatorImageElement", Type=System.Windows.Controls.Image)]
[TemplatePartAttribute(Name="AnimationElement", Type=System.Windows.Controls.Border)]
[TemplatePartAttribute(Name="ContentPresenter", Type=System.Windows.Controls.ContentPresenter)]
[TemplatePartAttribute(Name="ContentElement", Type=System.Windows.Controls.Grid)]
[TemplatePartAttribute(Name="MenuElement", Type=Intersoft.Client.UI.Aqua.UXMenu)]
[TemplatePartAttribute(Name="PointerElement", Type=System.Windows.Shapes.Path)]
[TemplatePartAttribute(Name="ItemsPresenter", Type=System.Windows.Controls.ItemsPresenter)]
[TemplatePartAttribute(Name="IndicatorElement", Type=System.Windows.Controls.Border)]
[TemplatePartAttribute(Name="IndicatorTemplateElement", Type=System.Windows.Controls.ContentControl)]
public ref class UXMenuItem : public Intersoft.Client.Framework.ISHeaderedSelectionControl, IControlIFramework, ILicensing, INavigationSourceINavigationSupportICommandSourceISelectionISelectionItem  

Example

XAML Copy Code
<Intersoft:UXMenuItem Header="Contact Us" Command="{Binding ContactCommand}"/>
<Intersoft:UXMenuItem Header="About Us" NavigateUri="www.mywebsite.com/contactus" TargetName="_blank"/>            

Remarks

UXMenuItem implements both ICommandSource and INavigationSource that allows both commanding and navigation using UXMenuItem. 

You can do commanding through Command, CommandTarget and CommandParameter properties, and navigation using NavigateUri and TargetName properties. To learn more about commanding, see Commanding Overview. To learn about navigation, see Navigation Overview.

Inheritance Hierarchy

System.Object
   System.Windows.DependencyObject
      System.Windows.UIElement
         System.Windows.FrameworkElement
            System.Windows.Controls.Control
               System.Windows.Controls.ItemsControl
                  Intersoft.Client.Framework.HeaderedItemsControl
                     Intersoft.Client.Framework.ISHeaderedItemsControl
                        Intersoft.Client.Framework.ISHeaderedSelectionControl
                           Intersoft.Client.UI.Aqua.UXMenuItem
                              Intersoft.Client.UI.Aqua.UXRibbon.UXRibbonMenuItem
                              Intersoft.Client.UI.Aqua.UXStackMenu.UXStackItem

Requirements

Target Platforms: Windows 98, Windows NT 4.0, Windows Millennium Edition, Windows 2000, Windows XP Home Edition, Windows XP Professional, Windows Server 2003 family, Windows Vista, Windows Server 2008 family

See Also

© 2012 All Rights Reserved.