2017-08-10 74 views
0

所以我在一個解決方案中有一個WPF項目和一個SharedProject。這個項目沒有引用Assembly'SharedProject1'

SharedProject有一個ResourceDictionary文件。我從我的WPF項目中引用了SharedProject。

enter image description here

但是當我嘗試引用ResourceDictionaryit給出了消息:「大會‘SharedProject1’不受此項目中引用」。

<Window x:Class="WPF.MainWindow" 
    xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" 
    xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" 
    xmlns:d="http://schemas.microsoft.com/expression/blend/2008" 
    xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006" 
    xmlns:local="clr-namespace:ietstesten" 
    mc:Ignorable="d" 
    Title="MainWindow" Height="350" Width="525"> 
<Window.Resources> 
    <ResourceDictionary Source="pack://application:,,,/SharedProject1;component/Dictionary1.xaml" /> 
</Window.Resources> 
<Grid> 

</Grid> 

回答

相關問題