Skip to main content

Microsoft Silverlight

Answered Question UIPropertyMetadata not foundRSS Feed

(0)

royhiggs
royhiggs

Member

Member

2 points

12 Posts

UIPropertyMetadata not found

When a create a dependency property and call DependencyProperty.Register I tried to use the following: 

public static readonly DependencyProperty ImageSourceProperty =

DependencyProperty.Register("ImageSource", typeof(string), typeof(ImageButton), new UIPropertyMetadata(""));

 However, I get an error in both VS2008 and Blend that UIPropertyMetadata could not be found. Does UIPropertyMetadata not exist anymore?

 Exact error message is and I do have System.Windows as a using statement.  

The type or namespace 'UIPropertyMetadata' could not be found (are you missing a using directive or an assembly reference?)

amit_pal1979
amit_pal...

Participant

Participant

1150 points

201 Posts

Answered Question

Re: UIPropertyMetadata not found

In WPF, we need to use UIPropertyMetaData however in SIlverlight Beta2 we have to use 'PropertyMetaData'.

 

Please mark this post as answered if the response was helpful

  • Unanswered Question
  • Answered Question
  • Announcement
Microsoft Communities