S'il vous plaît, je suis d'essayer d'attribuer à chaque bouton sur la gauche de son propre contrôle onglet. C'est par exemple, quand le bouton de formulaire d'admission est poussé, il aura son propre jeu d'onglets (ses propres contrôles tabulation)comment utiliser plusieurs contrôles onglet, et être en mesure d'appeler un onglet onglet contrôle avec des boutons
suis-je supposé placer plusieurs contrôles de tabulation sur la planche de travail, ou est-il un moyen de modifier par programme les noms des onglets, et leur contenu, quand un bouton est poussé sur la gauche?
merci d'avance.
et est ici un lien hxxp: //img709.imageshack.us/img709/554/tabcontrol.gif
est ici le code jusqu'à présent
<Window
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:d="http://schemas.microsoft.com/expression/blend/2008" xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
x:Class="service.MainWindow"
x:Name="Window"
Title="MainWindow"
Width="687" Height="480" mc:Ignorable="d">
<Window.Resources>
<Storyboard x:Key="OnLoaded1"/>
</Window.Resources>
<Window.Triggers>
<EventTrigger RoutedEvent="FrameworkElement.Loaded">
<BeginStoryboard Storyboard="{StaticResource OnLoaded1}"/>
</EventTrigger>
</Window.Triggers>
<Grid x:Name="LayoutRoot" Margin="0,0,-16,1">
<Grid.ColumnDefinitions>
<ColumnDefinition Width="0*"/>
<ColumnDefinition/>
</Grid.ColumnDefinitions>
<DockPanel Margin="8,8,0,7" LastChildFill="False" Grid.Column="1" HorizontalAlignment="Left" Width="660">
<Menu VerticalAlignment="Top" Width="657" Height="32">
<MenuItem x:Name="file" Header="File"/>
<MenuItem x:Name="edit" Header="Edit">
<MenuItem Width="100" Height="100" Header="MenuItem"/>
</MenuItem>
<MenuItem x:Name="view" Header="View"/>
<MenuItem x:Name="preferences" Header="Preferences"/>
<MenuItem x:Name="help" Header="Help"/>
</Menu>
</DockPanel>
<TabControl x:Name="tabwin" Margin="137.224,46,19,7" Grid.Column="1">
<TabItem x:Name="intakeformsub" Header="Elegibility Form">
<Grid HorizontalAlignment="Left" Width="490"/>
</TabItem>
<TabItem Header="TabItem">
<Grid/>
</TabItem>
<TabItem Header="TabItem">
<Grid/>
</TabItem>
<TabItem Header="TabItem">
<Grid>
<Grid.ColumnDefinitions>
<ColumnDefinition Width="0.567*"/>
<ColumnDefinition Width="0.433*"/>
</Grid.ColumnDefinitions>
</Grid>
</TabItem>
<TabItem Header="TabItem">
<Grid/>
</TabItem>
<TabItem Header="TabItem">
<Grid>
<Grid.ColumnDefinitions>
<ColumnDefinition Width="0.735*"/>
<ColumnDefinition Width="0.265*"/>
</Grid.ColumnDefinitions>
</Grid>
</TabItem>
<TabItem Header="TabItem">
<Grid/>
</TabItem>
<TabItem Header="TabItem">
<Grid/>
</TabItem>
</TabControl>
<Grid x:Name="___buttontab" Margin="11.205,61,0,0" Grid.Column="1" HorizontalAlignment="Left" Width="122.019" VerticalAlignment="Top" Height="276">
<Button VerticalAlignment="Top" Height="36" Content="Button"/>
<Button Margin="0,40,0,0" Content="Oasis Assessments" VerticalAlignment="Top" Height="36"/>
<Button Margin="0,80,0,0" VerticalAlignment="Top" Height="36" Content="Plan of Care"/>
<Button Margin="0,120,0,0" VerticalAlignment="Top" Height="36" Content="Medication Profile" RenderTransformOrigin="0.421,5.556"/>
<Button Margin="0,0,0,80" VerticalAlignment="Bottom" Height="36" Content="Clinical Notes"/>
<Button Margin="0,0,0,40" VerticalAlignment="Bottom" Height="36" Content="Infection Control"/>
<Button x:Name="intakeformbtn" VerticalAlignment="Top" Height="36" Content="Intake Form" Click="intakeform">
<Button.BindingGroup>
<BindingGroup/>
</Button.BindingGroup>
</Button>
<Button VerticalAlignment="Bottom" Height="36" Content="Discharge Summary"/>
</Grid>
<ProgressBar HorizontalAlignment="Left" Margin="8,0,0,7" VerticalAlignment="Bottom" Width="104.795" Height="19" Grid.Column="1"/>
</Grid>
</Window>
Personnellement, je donnerais chaque bouton de son propre contrôle onglet (avec plusieurs onglets), puis lorsque le bouton est cliqué, faire une animation pour glisser que le contrôle onglet depuis la droite et faire disparaître celui qui est déjà là. –