P
P
patamen2019-11-28 22:16:46
.NET
patamen, 2019-11-28 22:16:46

[C# WPF] Failed to resolve resource. What is the problem, how to solve it?

Good day!
I'm working on an application that contains a DataGrid table . In
addition to this, filters are required. I tried to install https://www.codeproject.com/Articles/42227/Automat...
On completion

<DataGrid ColumnHeaderStyle="{StaticResource {ComponentResourceKey 
           TypeInTargetAssembly={x:Type filter:DataGridHeaderFilterControl}, 
           ResourceId=DataGridHeaderFilterControlStyle}}"/>

Gives an error
"Failed to resolve the resource"
Tried to additionally connect the resource separately
<Window.Resources>
        <ResourceDictionary>
            <ResourceDictionary.MergedDictionaries>
                <ResourceDictionary Source="pack://application:,,,/DataGridFilterLibrary;component/Themes/Generic.xaml" />
            </ResourceDictionary.MergedDictionaries>
        </ResourceDictionary>
    </Window.Resources>

The error has not disappeared~
How can I solve the problem? Or maybe there is something simpler for filters (like Excel autofilters)?..
NuGet:
Name: DataGridFilter
Version: 1.0.3
URL : https://github.com/qusma/DataGridFilter /www.codeproject.com/Articles/42227/Automat...

Answer the question

In order to leave comments, you need to log in

1 answer(s)
R
Roman, 2019-11-29
@yarosroman

And namespace all registered in xaml? Like in the example?

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question