Reputation: 93
Hello How I can find GotFocus event into the PivotItem I had tired with GalaSoft Interaction with Triger and EventName="GotFocus" but it is not fired can anybody help me to find the PivioItem Event.
Thank you.
Upvotes: 1
Views: 344
Reputation: 77
Yes,
here you are the solution:
<controls:Pivot Title="My Pivot">
<i:Interaction.Triggers>
<i:EventTrigger EventName="SelectionChanged">
<i:InvokeCommandAction Command="{Binding EuropePivotSelectedCommand}" />
</i:EventTrigger>
</i:Interaction.Triggers>
<controls:PivotItem Header="item1">
</controls:PivotItem>
<controls:PivotItem Header="item2">
</controls:PivotItem>
Regards Juanlu, ElGuerre
Upvotes: 0
Reputation: 2012
the pivot item gets focus upon cliking any control placed inside that pivot item.
<controls:PivotItem Header="item1">
<i:Interaction.Triggers>
<i:EventTrigger EventName="GotFocus">
<i:InvokeCommandAction Command="{Binding ShowMessageCommand}" />
</i:EventTrigger>
</i:Interaction.Triggers>
<Grid>
<TextBox Height="100"
Width="200"/>
<Button Height="100"
Width="200" />
</Grid>
</controls:PivotItem>
This code works for me. the pivot item get focus upon clicking the button or the text box. Hope this helps you.
Upvotes: 1