|
Cet article a fait l'objet d'une traduction automatique. Déplacez votre pointeur sur les phrases de l'article pour voir la version originale de ce texte. Informations supplémentaires.
|
Traduction
Source
|
ExpandDirection, énumération
.NET Framework 4.5
Espace de noms : System.Windows.Controls
Assembly : PresentationFramework (dans PresentationFramework.dll)
<StackPanel> <RadioButton Name="ExpandDown" Margin="0,10,0,10" IsChecked="True" Checked="ChangeExpandDirection" GroupName="ExpandDirectionProperty"> Expand Down </RadioButton> <RadioButton Name="ExpandUp" Margin="0,0,0,10" Checked="ChangeExpandDirection" GroupName="ExpandDirectionProperty"> Expand Up </RadioButton> <RadioButton Name="ExpandLeft" Margin="0,0,0,10" Checked="ChangeExpandDirection" GroupName="ExpandDirectionProperty"> Expand Left </RadioButton> <RadioButton Name="ExpandRight" Margin="0,0,0,10" Checked="ChangeExpandDirection" GroupName="ExpandDirectionProperty"> Expand Right </RadioButton> </StackPanel>
Private Sub ChangeExpandDirection(ByVal Sender As Object, ByVal e As RoutedEventArgs) If (ExpandDown.IsChecked) Then myExpander.ExpandDirection = ExpandDirection.Down ElseIf (ExpandUp.IsChecked) Then myExpander.ExpandDirection = ExpandDirection.Up ElseIf (ExpandLeft.IsChecked) Then myExpander.ExpandDirection = ExpandDirection.Left ElseIf (ExpandRight.IsChecked) Then myExpander.ExpandDirection = ExpandDirection.Right End If 'Expand myExpander so it is easier to see the effect of changing 'the ExpandDirection property for My Expander myExpander.IsExpanded = True End Sub
private void ChangeExpandDirection(object sender, RoutedEventArgs e) { if ((Boolean)ExpandDown.IsChecked) myExpander.ExpandDirection = ExpandDirection.Down; else if ((Boolean)ExpandUp.IsChecked) myExpander.ExpandDirection = ExpandDirection.Up; else if ((Boolean)ExpandLeft.IsChecked) myExpander.ExpandDirection = ExpandDirection.Left; else if ((Boolean)ExpandRight.IsChecked) myExpander.ExpandDirection = ExpandDirection.Right; //Expand myExpander so it is easier to see the effect of changing //the ExpandDirection property for My Expander myExpander.IsExpanded = true; }
Windows 8, Windows Server 2012, Windows 7, Windows Vista SP2, Windows Server 2008 (rôle principal du serveur non pris en charge), Windows Server 2008 R2 (rôle principal du serveur pris en charge avec SP1 ou version ultérieure ; Itanium non pris en charge)
Le .NET Framework ne prend pas en charge toutes les versions de chaque plateforme. Pour obtenir la liste des versions prises en charge, consultez Configuration requise du .NET Framework.