WPF Designer Crash
-
I've been messing around with C# for about a year or so and I thought I'd have a look to see what WPF is all about. However I'm having a problem. Here's the problem - If I drag a control (Button, TextBox TextBlock ,whatever) and I try to access the FontFamily property in the Poperties window then the designer will crash with the following error - System.ArgumentException An item with the same key has already been added. at System.ThrowHelper.ThrowArgumentException(ExceptionResource resource) at System.Collections.Generic.Dictionary`2.Insert(TKey key, TValue value, Boolean add) at MS.Internal.FontFace.PhysicalFontFamily.ConvertDictionary(IDictionary`2 dictionary) at MS.Internal.FontFace.PhysicalFontFamily.MS.Internal.FontFace.IFontFamily.get_Names() at System.Windows.Media.FontFamily.get_FamilyNames() at MS.Internal.Services.WPFFontPlatformService.GetFontFamilyName(FontFamily fontFamily) at MS.Internal.Services.WPFFontPlatformService.GetSupportedFamilyNames() at MS.Internal.Designer.PropertyEditing.Editors.FontEditor.FontList.Refresh(EditingContext context) at MS.Internal.Designer.PropertyEditing.Editors.FontEditor.FontList.GetEnumerator() at MS.Internal.Data.EnumerableCollectionView.LoadSnapshotCore(IEnumerable source) at MS.Internal.Data.EnumerableCollectionView..ctor(IEnumerable source) at MS.Internal.Data.ViewManager.GetViewRecord(Object collection, CollectionViewSource cvs, Type collectionViewType, Boolean createView) at MS.Internal.Data.DataBindEngine.GetViewRecord(Object collection, CollectionViewSource key, Type collectionViewType, Boolean createView) at System.Windows.Data.CollectionViewSource.GetDefaultCollectionView(Object source, Boolean createView) at System.Windows.Data.CollectionViewSource.GetDefaultCollectionView(Object source, DependencyObject d) at System.Windows.Controls.ItemCollection.SetItemsSource(IEnumerable value) at System.Windows.Controls.ItemsControl.OnItemsSourceChanged(DependencyObject d, DependencyPropertyChangedEventArgs e) at System.Windows.DependencyObject.OnPropertyChanged(DependencyPropertyChangedEventArgs e) at System.Windows.FrameworkElement.OnPropertyChanged(DependencyPropertyChangedEventArgs e) at System.Windows.DependencyObject.NotifyPropertyChange(DependencyPropertyChangedEventArgs args) at System.Windows.DependencyObject.UpdateEffectiveValue(EntryIndex entryIndex, DependencyProperty dp, PropertyMetadata metadata, EffectiveValueEntry oldEntry, EffectiveValueEntry& newEntry, Boolean
-
I've been messing around with C# for about a year or so and I thought I'd have a look to see what WPF is all about. However I'm having a problem. Here's the problem - If I drag a control (Button, TextBox TextBlock ,whatever) and I try to access the FontFamily property in the Poperties window then the designer will crash with the following error - System.ArgumentException An item with the same key has already been added. at System.ThrowHelper.ThrowArgumentException(ExceptionResource resource) at System.Collections.Generic.Dictionary`2.Insert(TKey key, TValue value, Boolean add) at MS.Internal.FontFace.PhysicalFontFamily.ConvertDictionary(IDictionary`2 dictionary) at MS.Internal.FontFace.PhysicalFontFamily.MS.Internal.FontFace.IFontFamily.get_Names() at System.Windows.Media.FontFamily.get_FamilyNames() at MS.Internal.Services.WPFFontPlatformService.GetFontFamilyName(FontFamily fontFamily) at MS.Internal.Services.WPFFontPlatformService.GetSupportedFamilyNames() at MS.Internal.Designer.PropertyEditing.Editors.FontEditor.FontList.Refresh(EditingContext context) at MS.Internal.Designer.PropertyEditing.Editors.FontEditor.FontList.GetEnumerator() at MS.Internal.Data.EnumerableCollectionView.LoadSnapshotCore(IEnumerable source) at MS.Internal.Data.EnumerableCollectionView..ctor(IEnumerable source) at MS.Internal.Data.ViewManager.GetViewRecord(Object collection, CollectionViewSource cvs, Type collectionViewType, Boolean createView) at MS.Internal.Data.DataBindEngine.GetViewRecord(Object collection, CollectionViewSource key, Type collectionViewType, Boolean createView) at System.Windows.Data.CollectionViewSource.GetDefaultCollectionView(Object source, Boolean createView) at System.Windows.Data.CollectionViewSource.GetDefaultCollectionView(Object source, DependencyObject d) at System.Windows.Controls.ItemCollection.SetItemsSource(IEnumerable value) at System.Windows.Controls.ItemsControl.OnItemsSourceChanged(DependencyObject d, DependencyPropertyChangedEventArgs e) at System.Windows.DependencyObject.OnPropertyChanged(DependencyPropertyChangedEventArgs e) at System.Windows.FrameworkElement.OnPropertyChanged(DependencyPropertyChangedEventArgs e) at System.Windows.DependencyObject.NotifyPropertyChange(DependencyPropertyChangedEventArgs args) at System.Windows.DependencyObject.UpdateEffectiveValue(EntryIndex entryIndex, DependencyProperty dp, PropertyMetadata metadata, EffectiveValueEntry oldEntry, EffectiveValueEntry& newEntry, Boolean