視覚的な状態でカスタム添付プロパティを設定しようとしていますが、完全な名前空間を使用して、エイリアスを使用せずに、いくつかの方法を試しましたが、成功しませんでしたか?
xmlns:p="using:Controls.Views.Properties"
<RelativePanel x:Name="RootPanel" Background="{ThemeResource ApplicationPageBackgroundThemeBrush}">
<VisualStateManager.VisualStateGroups>
<VisualStateGroup x:Name="VisualStateGroup">
<VisualState x:Name="NarrowView">
<VisualState.StateTriggers>
<AdaptiveTrigger MinWindowWidth="0" />
</VisualState.StateTriggers>
<VisualState.Setters>
//This is where the value is not achieved
<Setter Target="Text.(p:RelativeSize.Width)" Value="0.5"/>
エラーが発生するだけでなく、 p: を j: に置き換えることができ、クラッシュしません。それを解決する方法がわかりません。
この質問は、ここでソリューションを終了することです: UWP アプリを使用した XAML での RelativePanel を使用した UI 要素の相対幅