I'm an absolute beginner with WPF and tried to play around with
some of the examples I found.
Here is the problem:
I want to create an Image control as a child of the default Grid created
by the designer and set its Source property in Xaml.
Here is my Xaml:
Title="Window1" Height="300" Width="300">
The image file exists in the project folder but the designer immediately
gives me the following error:
ErrorÃÂ 1ÃÂ The file test.png is not part of the project or its 'Build Action' property is not set to 'Resource'.ÃÂ D:\CSharp\Test\WpfApplication1\Window1.xamlÃÂ 6ÃÂ 16ÃÂ WpfApplication1
When I add the file to the project and set its Build Action to Resource the image is
displayed at runtime. The problem is the designer still insists on the above mentioned
error and does not display anything except for the information:
The document contains errors that must be fixed before the designer can be
loaded. Reload the designer after you have fixed the errors.
Reload the designer
What am I doing wrong?
(I am using Visual C# 2008 Expre
View Complete Post