I have a RadTabControl with a Custom ContentTemplate. It works fine, and displays the content as I'd expect when first viewing the tab. However, when changing from one tab, back to the original tab, I find that the data inside the content presenter is no longer being displayed. It appears as if the DataContext or ItemsSource binding is no longer being applied as I'd expect.
Below is a short expample which should illustrade what I'm seeing. I'm using MVVM, and the ClosedOrderCol in the code snippet below is an ObservableCollection on the ViewModel.
Any help would be appreciated.
Below is a short expample which should illustrade what I'm seeing. I'm using MVVM, and the ClosedOrderCol in the code snippet below is an ObservableCollection on the ViewModel.
Any help would be appreciated.
<Navigation:RadTabControl> |
<Navigation:RadTabControl.ItemContainerStyle> |
<Setter Property="ContentTemplate"> |
<Setter.Value> |
<DataTemplate> <Grid> |
<ContentPresenter Content="{TemplateBinding Content}"/> </Grid> |
</DataTemplate> |
</Setter.Value> |
</Setter> |
</Navigation:RadTabControl.ItemContainerStyle> |
<Navigation:RadTabItem> |
<Controls:RadGridView Grid.Row="1" ItemsSource="{Binding ClosedOrderCol}" IsReadOnly="True"> |
<Controls:RadGridView.Columns> |
<Controls:GridViewDataColumn Header="Closed" DataMemberBinding="{Binding DateClosed}" /> |
</Controls:RadGridView> |
</Navigation:RadTabItem> |
<Navigation:RadTabItem /> |
<Navigation:RadTabControl> |