Visual Studio Development Bookmark and Share   
 index > Visual Studio WPF Designer > 'System.Windows.Freezable' is defined in an assembly that is not referenced
 

'System.Windows.Freezable' is defined in an assembly that is not referenced

Hi all,

I'm using VS2008, I have this line of code in my page_load and I already added PresentationCore.dll to my reference but I'm getting the error message below.

RenderTargetBitmap rtb= new RenderTargetBitmap(180, 180, 120, 96, PixelFormats.Pbgra32);

This is the error message:

The type 'System.Windows.Freezable' is defined in an assembly that is not referenced. You must add a reference to assembly 'WindowsBase, Version=3.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35'.C:\Documents and Settings\tfetalvero\My Documents\Visual Studio 2008\Projects\SilverlightProject1\SilverlightProject1\Page.xaml.cs2214SilverlightProject1

Thanks

Teo  Tuesday, March 04, 2008 12:48 AM
From your path, it appears you are loading a Silverlight project? If so, VS 2008 does not support Silverlight projects, only WPF.

Jim Nakashima  Tuesday, March 04, 2008 3:10 AM
From your path, it appears you are loading a Silverlight project? If so, VS 2008 does not support Silverlight projects, only WPF.

Jim Nakashima  Tuesday, March 04, 2008 3:10 AM
Just give the "WindowsBase" to the References.
(In "Solution Explorer" right-click on "References", "Add References...", and select the "WindowsBase" from ".Net" page.)
jmadar  Tuesday, April 14, 2009 6:51 PM
I had the same problem with my Autodesk Revit menu I add "WindowsBase" to my references and that solve my problems. 
RodTex  Wednesday, October 07, 2009 6:31 PM

You can use google to search for other answers

Custom Search

More Threads

• why TabIndex property is not working properly OR what is the use of TabIndex propery in WPF.?
• Design Surface in CIDER
• Unhandled exception in VS 2008 Designer - XAML/WPF
• Confirm a bug: ObjectDataProvider Designer Bug
• Making a Datgrid into a User Control loses the data
• Displaying a user control from another user control
• Expression Blend animations - integrating into current VStudio 2008 SP1 website
• "Property [...] was not found or is not serializable for type Button" ??
• Free .NET 3.0 E-Learning
• WPF designer won't load when binding datasource from entity model