Reputation: 1071
I added refernence of System.Windows.dll to my project cos i need it some pages but lots of error pop outs like
The type 'System.Windows.MessageBox' exists in both 'C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework.NETFramework\v4.0\Profile\Client\PresentationFramework.dll' and 'C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\Silverlight\v4.0\System.Windows.dll'
and
The type 'System.Windows.RoutedEventArgs' exists in both 'C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework.NETFramework\v4.0\Profile\Client\PresentationCore.dll' and 'C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\Silverlight\v4.0\System.Windows.dll'
and many more errors that says exist is both assemblies . How do i fix this?
Upvotes: 0
Views: 452
Reputation: 650
Maybe try explicitly naming the namespace that you want to use.
Something like:
[System.Windows.MessageBox]
private void SomeMethod()
{
MessageBox.Show("SomeText");
}
or
System.Windows.MessageBox.Show("SomeText");
Upvotes: 0
Reputation: 360
What about full qualifying the types you are using in your class and / or defining alias names for your using directives. Does this work ?
Upvotes: 0