HandyControl icon indicating copy to clipboard operation
HandyControl copied to clipboard

把WPF项目从.NET Framework 4.8通过Visual Studio的Upgrade选项升级到.NET 8.0后,某些页面出现崩溃问题

Open adriel2012 opened this issue 7 months ago • 0 comments

Describe the bug

经过我一段时间的排查,发现只要是使用了ListBox、Combobox、DataGrid控件的界面,跳转到这些界面的时候就会报这个异常,我尝试把这些控件通过Style={x:Null}屏蔽掉HandyControl的全局默认样式之后,异常就不会再出现了。

另外,我尝试新建了一个.NET 8.0的测试项目,引用了HandyControl,并且在测试的界面中添加了ListBox、Combobox、DataGrid控件,发现一切正常,没有出现上面提到的异常。这是什么原因?我该如何解决这个问题?

Steps to reproduce the bug

我的程序就是,点击主界面的某一个按钮,跳转到相应的子界面,然后就出现异常了

Expected behavior

No response

Screenshots

Snipaste_2023-12-28_14-01-28

NuGet package version

None

IDE

Visual Studio 2022

Framework type

.Net Framework 4.8

Windows version

Windows 11 (22000)

Additional context

No response

adriel2012 avatar Dec 28 '23 06:12 adriel2012