Compiler can't find Calendar?

Mar 18, 2009 at 3:46 PM

I am getting an error that I don't understand while loading the Calendar (01/09 WPF toolkit) at run-time. The Calendar is sited on a UserControl, which loads fine at design-time. But at run-time, I get this message:

Cannot find type 'Microsoft.Windows.Controls.Calendar'. The assembly used when compiling might be different than that used when loading and the type is missing.  Error at object 'System.Windows.Controls.Grid' in markup file 'MyUserControl.xaml' Line 15 Position 10.

I am puzzled by the error because I have referenced the WPF toolkit in my project, and I have declared the toolkit namespace in my XAML. The UserControl contains this namespace declaration for the toolkit:

<UserControl x:Class="MyUserControl" ...
     xmlns:toolkit="" ... />

Then I declare the calendar like this:

<toolkit:Calendar Height="160" ...  />





The error message sounds like I've got my namespace declaration wrong, but I don't see the error. Can you tell me what the error is? Thanks.

David Veeneman
Foresight Systems

Mar 18, 2009 at 6:31 PM
Never did figure out the error. Deleted the calendar and re-added it to the UserControl. Loading fine now.