【发布时间】:2018-08-06 14:04:47
【问题描述】:
我在文件 hints.xaml 中保存了许多工具提示。像这样:
<ResourceDictionary xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:local="clr-namespace:WpfApp7.Theme"
x:Class="WpfApp7.Theme.Hints">
<ToolTip x:Key="myToolTip" >
<StackPanel >
<Label Content="Nadpis" />
<TextBlock Text="................"/>
</StackPanel>
</ToolTip>
</ResourceDictionary>
如何在我的 Text="................" 上绑定 Enviroment.CurrentDictionary 类的字符串?
我尝试为 Hints.xaml 创建代码并通过 DataContext 绑定但没有工作。
【问题讨论】: