Hi,
Is there any way to utilize AdaptiveTriggers with RadDataGrid for UWP?
I'd like to accomplish something like that but obviously it does not work (the MyDataGrid.Columns[1].Header element is not recognized):
<telerikGrid:RadDataGrid x:Name="MyDataGrid"
ItemsSource="{x:Bind MyCollection}"
AutoGenerateColumns="False">
<telerikGrid:RadDataGrid.Columns>
<telerikGrid:DataGridTextColumn x:Name="Column1" PropertyName="Prop1" Header="Prop1" />
<telerikGrid:DataGridTextColumn PropertyName="Prop2" Header="Prop2" />
<telerikGrid:DataGridTextColumn PropertyName="Prop3" Header="Prop3" />
</telerikGrid:RadDataGrid.Columns>
</telerikGrid:RadDataGrid>
<VisualStateManager.VisualStateGroups>
<VisualStateGroup>
<VisualState x:Name="NarrowState">
<VisualState.StateTriggers>
<AdaptiveTrigger MinWindowWidth="1" />
</VisualState.StateTriggers>
<VisualState.Setters>
<!-- nothing to change for now -->
</VisualState.Setters>
</VisualState>
<VisualState x:Name="NormalState">
<VisualState.StateTriggers>
<AdaptiveTrigger MinWindowWidth="720" />
</VisualState.StateTriggers>
<VisualState.Setters>
<!-- this does not work -->
<Setter Target="MyDataGrid.Columns[0].Header" Value="New header" />
</VisualState.Setters>
</VisualState>
<VisualState x:Name="WideState">
<VisualState.StateTriggers>
<AdaptiveTrigger MinWindowWidth="1366" />
</VisualState.StateTriggers>
<VisualState.Setters>
<!-- nothing to change for now -->
</VisualState.Setters>
</VisualState>
</VisualStateGroup>
</VisualStateManager.VisualStateGroups>
Thanks,
Leszek