Xaml 在AppBar按钮中引用resources.resw

Xaml 在AppBar按钮中引用resources.resw,xaml,windows-runtime,winrt-xaml,Xaml,Windows Runtime,Winrt Xaml,我需要在AppBar按钮中引用resources.resw-file中的文本,但它被设置为AutomationProperties.Name=”“ 我不能将它作为AppBarSearch.AutomationProperties.Name添加到resources.resw中,那么我如何引用它呢?AutomationProperties.Name是一个附加属性,您需要处理它,即您需要在资源键中包含它的命名空间: AppBarSearch.[using:Windows.UI.Xaml.Automat

我需要在AppBar按钮中引用resources.resw-file中的文本,但它被设置为
AutomationProperties.Name=”“


我不能将它作为
AppBarSearch.AutomationProperties.Name添加到resources.resw中,那么我如何引用它呢?

AutomationProperties.Name
是一个附加属性,您需要处理它,即您需要在资源键中包含它的命名空间:

AppBarSearch.[using:Windows.UI.Xaml.Automation]AutomationProperties.Name

谢谢你的帮助,因为我不知道如何让它工作