C# 'ResourceDictionaryCollection' does not exist

1k Views Asked by At

I am Getting Error shown below:

  Error 1   The tag 'ResourceDictionaryCollection' does not exist in XML
     namespace 'clr-namespace:System.Windows.Controls.DataVisualization;
    assembly=System.Windows.Controls.DataVisualization.Toolkit'.

Here is the Code:

             xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
             xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
             xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006" 
             xmlns:d="http://schemas.microsoft.com/expression/blend/2008" 
             xmlns:DV="clr-namespace:System.Windows.Controls.DataVisualization;assembly=System.Windows.Controls.DataVisualization.Toolkit"
             xmlns:DVC="clr-namespace:System.Windows.Controls.DataVisualization.Charting;assembly=System.Windows.Controls.DataVisualization.Toolkit"
             mc:Ignorable="d" 
             MinHeight="384" MinWidth="579">
    <UserControl.Resources>
        <DV:ResourceDictionaryCollection x:Key="MyPalette">
            <ResourceDictionary>
                <Style x:Key="DataPointStyle" TargetType="Control">
                    <Setter Property="Background" Value="Purple" />
                </Style>
            </ResourceDictionary>

How Should I correct this Error? I am running on Visual C# 2010. I have Installed WPF ToolKit and Still I am getting the namespace error.

1

There are 1 best solutions below

0
On BEST ANSWER

I found the solution by replacing original System.Windows.Controls.DataVisualization.Toolkit.dll with System.Windows.Controls.DataVisualization.Toolkit.dll found in https://code.google.com/p/adsense-windows-gadget/source/checkout

I guess it might be a version problem...