在我再次運行下面的代碼之前,如何知道「Status」DependencyProperty是否已註冊?檢查DependencyProperty已註冊
代碼:
public readonly DependencyProperty StatusProperty ;
public string Status
{
get { return (string)GetValue(StatusProperty); }
set { SetValue(StatusProperty, value); }
}
StatusProperty = DependencyProperty.Register("Status", typeof(string), typeof(CWindow), new PropertyMetadata());
http://social.msdn.microsoft.com/Forums/en/wpf/thread/cdd0dcdf-9187-4cd9-80de-4d3f51a4f970 – Klaus78