Exception:在 'System.Windows.Markup.StaticResourceHolder' 上提供值時擲回例外狀況。找不到名為 'MyPropertyItemsControlStyle' 的資源。資源名稱會區分大小寫。

报错信息 1
XamlParseException: 在 'System.Windows.Markup.StaticResourceHolder' 上提供值時擲回例外狀況。
--LineNumber: 0
--LinePosition: 0
StackTrace:
   於 System.Windows.Markup.XamlReader.RewrapException(Exception e, IXamlLineInfo lineInfo, Uri baseUri)
   於 System.Windows.FrameworkTemplate.LoadTemplateXaml(XamlReader templateReader, XamlObjectWriter currentWriter)
   於 System.Windows.FrameworkTemplate.LoadTemplateXaml(XamlObjectWriter objectWriter)
   於 System.Windows.FrameworkTemplate.LoadOptimizedTemplateContent(DependencyObject container, IComponentConnector componentConnector, IStyleConnector styleConnector, List`1 affectedChildren, UncommonField`1 templatedNonFeChildrenField)
   於 System.Windows.FrameworkTemplate.LoadContent(DependencyObject container, List`1 affectedChildren)
   於 System.Windows.StyleHelper.ApplyTemplateContent(UncommonField`1 dataField, DependencyObject container, FrameworkElementFactory templateRoot, Int32 lastChildIndex, HybridDictionary childIndexFromChildID, FrameworkTemplate frameworkTemplate)
   於 System.Windows.FrameworkTemplate.ApplyTemplateContent(UncommonField`1 templateDataField, FrameworkElement container)
   於 System.Windows.FrameworkElement.ApplyTemplate()
   於 System.Windows.FrameworkElement.MeasureCore(Size availableSize)
   於 System.Windows.UIElement.Measure(Size availableSize)
   於 MS.Internal.Helper.MeasureElementWithSingleChild(UIElement element, Size constraint)
   於 System.Windows.Controls.ScrollContentPresenter.MeasureOverride(Size constraint)
   於 System.Windows.FrameworkElement.MeasureCore(Size availableSize)
   於 System.Windows.UIElement.Measure(Size availableSize)
   於 System.Windows.Controls.Grid.MeasureCell(Int32 cell, Boolean forceInfinityV)
   於 System.Windows.Controls.Grid.MeasureCellsGroup(Int32 cellsHead, Size referenceSize, Boolean ignoreDesiredSizeU, Boolean forceInfinityV, Boolean& hasDesiredSizeUChanged)
   於 System.Windows.Controls.Grid.MeasureOverride(Size constraint)
   於 System.Windows.FrameworkElement.MeasureCore(Size availableSize)
   於 System.Windows.UIElement.Measure(Size availableSize)
   於 System.Windows.Controls.ScrollViewer.MeasureOverride(Size constraint)
   於 System.Windows.FrameworkElement.MeasureCore(Size availableSize)
   於 System.Windows.UIElement.Measure(Size availableSize)
   於 MS.Internal.Helper.MeasureElementWithSingleChild(UIElement element, Size constraint)
   於 System.Windows.Controls.ContentPresenter.MeasureOverride(Size constraint)
   於 System.Windows.FrameworkElement.MeasureCore(Size availableSize)
   於 System.Windows.UIElement.Measure(Size availableSize)
   於 System.Windows.Controls.Border.MeasureOverride(Size constraint)
   於 System.Windows.FrameworkElement.MeasureCore(Size availableSize)
   於 System.Windows.UIElement.Measure(Size availableSize)
   於 System.Windows.Controls.Grid.MeasureCell(Int32 cell, Boolean forceInfinityV)
   於 System.Windows.Controls.Grid.MeasureCellsGroup(Int32 cellsHead, Size referenceSize, Boolean ignoreDesiredSizeU, Boolean forceInfinityV, Boolean& hasDesiredSizeUChanged)
   於 System.Windows.Controls.Grid.MeasureOverride(Size constraint)
   於 System.Windows.FrameworkElement.MeasureCore(Size availableSize)
   於 System.Windows.UIElement.Measure(Size availableSize)
   於 System.Windows.Controls.Control.MeasureOverride(Size constraint)
   於 System.Windows.FrameworkElement.MeasureCore(Size availableSize)
   於 System.Windows.UIElement.Measure(Size availableSize)
   於 System.Windows.Controls.DockPanel.MeasureOverride(Size constraint)
   於 System.Windows.FrameworkElement.MeasureCore(Size availableSize)
   於 System.Windows.UIElement.Measure(Size availableSize)
   於 MS.Internal.Helper.MeasureElementWithSingleChild(UIElement element, Size constraint)
   於 System.Windows.Controls.ContentPresenter.MeasureOverride(Size constraint)
   於 System.Windows.FrameworkElement.MeasureCore(Size availableSize)
   於 System.Windows.UIElement.Measure(Size availableSize)
   於 System.Windows.Controls.Border.MeasureOverride(Size constraint)
   於 System.Windows.FrameworkElement.MeasureCore(Size availableSize)
   於 System.Windows.UIElement.Measure(Size availableSize)
   於 System.Windows.Controls.Page.MeasureOverride(Size constraint)
   於 System.Windows.FrameworkElement.MeasureCore(Size availableSize)
   於 System.Windows.UIElement.Measure(Size availableSize)
   於 MS.Internal.Helper.MeasureElementWithSingleChild(UIElement element, Size constraint)
   於 System.Windows.Controls.ContentPresenter.MeasureOverride(Size constraint)
   於 System.Windows.FrameworkElement.MeasureCore(Size availableSize)
   於 System.Windows.UIElement.Measure(Size availableSize)
   於 System.Windows.ContextLayoutManager.UpdateLayout()
   於 System.Windows.ContextLayoutManager.UpdateLayoutCallback(Object arg)
   於 System.Windows.Media.MediaContext.FireInvokeOnRenderCallbacks()
   於 System.Windows.Media.MediaContext.RenderMessageHandlerCore(Object resizedCompositionTarget)
   於 System.Windows.Media.MediaContext.RenderMessageHandler(Object resizedCompositionTarget)
   於 System.Windows.Threading.ExceptionWrapper.InternalRealCall(Delegate callback, Object args, Int32 numArgs)
   於 System.Windows.Threading.ExceptionWrapper.TryCatchWhen(Object source, Delegate callback, Object args, Int32 numArgs, Delegate catchHandler)

Exception: 找不到名為 'MyPropertyItemsControlStyle' 的資源。資源名稱會區分大小寫。
StackTrace:
   於 System.Windows.StaticResourceExtension.ProvideValueInternal(IServiceProvider serviceProvider, Boolean allowDeferredReference)
   於 MS.Internal.Xaml.Runtime.ClrObjectRuntime.CallProvideValue(MarkupExtension me, IServiceProvider serviceProvider)

版本:1.45.5 2026-06-24 11:32 Microsoft Windows NT 10.0.26200.0