Quantcast
Channel: Windows Presentation Foundation (WPF) forum
Viewing all articles
Browse latest Browse all 18858

'Provide value on 'System.Windows.Markup.StaticResourceHolder' threw an exception.'

$
0
0

I am getting XAML exception in below code:

<Window x:Class="TemplatingOverview.MainWindow"
        xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
        xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
        xmlns:myTemplateSelector="clr-namespace:TemplatingOverview"
        Title="MainWindow" Height="350" Width="525"><Window.Resources><myTemplateSelector:MyTemplateSelector x:Key="dataTemplateSelectorDictionary"
                     StandardTemplate="{StaticResource StandardTemplate}"
                     BelowAverageTemplate="{StaticResource BelowAverageTemplate}"/>  </Window.Resources><Grid><StackPanel><ListView Name="listView" Margin="10" ItemsSource="{Binding EmployeeDetails}" HorizontalContentAlignment="Stretch"><ListView.View><GridView><GridViewColumn DisplayMemberBinding="{Binding Path=FirstName}" 
                                        CellTemplateSelector="{StaticResource dataTemplateSelectorDictionary}"
                                        Header="First Name" Width="100"></GridViewColumn><GridViewColumn DisplayMemberBinding="{Binding Path=Age}"
                                    Header="Age" Width="80"/></GridView></ListView.View></ListView></StackPanel></Grid></Window>



Regards, http://www.shwetalodha.blogspot.in/


Viewing all articles
Browse latest Browse all 18858

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>