Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
我目前正在使用本机 Windows 控件,它应该出现在我的 WPF 设计视图中,但是当我关闭设计选项卡时,它会使整个 IDE 崩溃。
有没有做以下任何一个?
我的特定本机控件是Scintilla,我用HwndHost显示。
您需要插入对设计模式的检查,并执行仅在您未处于设计模式时才会导致问题的代码。
看:
WPF 中是否有 DesignMode 属性?