Hi Support,
We are using the XamDockManager as the region manager like this:
<igDock:XamDockManager Grid.Row="1" Grid.ColumnSpan="2"> <igDock:DocumentContentHost> <igDock:SplitPane> <igDock:TabGroupPane prism:RegionManager.RegionName="{x:Static core:RegionNames.Test}"> <igDock:TabGroupPane.Resources> <Style TargetType="{x:Type igDock:ContentPane}" BasedOn="{StaticResource DefaultContentPaneStyle}"> <Setter Property="AllowClose" Value="False" /> </Style> </igDock:TabGroupPane.Resources> </igDock:TabGroupPane> </igDock:SplitPane> </igDock:DocumentContentHost> </igDock:XamDockManager>
We'll add several tab to this dock manager in the view model. Now we have one new requirement: Do some actions once user select certain tab(not every tab).
How to achieve this?
thanks,
Eric
Hello Eric,
Thank you for your post!
To do this, I would recommend that you handle one of two events. These two events are the SelectionChanged event on the TabGroupPane or the ActivePaneChanged event on the XamDockManager. Both of these events will allow you to check the newly activated pane and perform your actions that you need to perform on certain tab selections.
You can check the newly activated pane from the event arguments of both of the event handlers from these events. The e.NewValue property of the XamDockManager.ActivePaneChanged event will give you this, as will checking the e.AddedItems collection of the TabGroupPane.SelectionChanged event. If you check these panes in an if-statement in these event handlers, you can choose whether or not to perform your action on that particular content pane's activation.
I hope this helps you. Please let me know if you have any other questions or concerns on this matter.
Sincerely,AndrewAssociate DeveloperInfragistics Inc.www.infragistics.com/support