[英]WPF Presentation Framework Exception
I am having an issue with my WPF application throwing the following exception:我的 WPF 应用程序出现问题,引发以下异常:
An unhandled exception of type 'System.Reflection.TargetInvocationException' occurred in PresentationFramework.dll
PresentationFramework.dll 中发生类型为“System.Reflection.TargetInvocationException”的未处理异常
Additional information: Exception has been thrown by the target of an invocation.
附加信息:调用的目标已抛出异常。
The exception occurs inside the InitializeComponent();
异常发生在
InitializeComponent();
内部InitializeComponent();
on the main window:在主窗口上:
<Window xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
mc:Ignorable="d" x:Class="NationStates_Telegram_Suite.MainWindow"
Title="NationStates Telegram Suite" Height="475" Width="610"
ResizeMode="CanMinimize">
of the xaml.的xaml。 VS Gives me the option to step inside the dll and it is broken at this line if that helps:
VS 给了我进入 dll 的选项,如果有帮助,它会在这一行被破坏:
55F94E4B push dword ptr [ebp+8]
I have commented out everything I think I tried commenting out all of the code changes I made to know avail.我已经注释掉了我认为我尝试注释掉所有我知道有用的代码更改的所有内容。 How does one resolve this?
怎么解决这个问题?
One strategy to employ is to remove any bindings in the xaml and run until the problem stops.采用的一种策略是删除 xaml 中的所有绑定并运行,直到问题停止。
There may be a race condition with a binding and initialization which is occurring.可能存在正在发生的绑定和初始化的竞争条件。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.