Exception:无效的设备上下文(DC)句柄。

报错信息 1
Win32Exception: 无效的设备上下文(DC)句柄。
--NativeErrorCode: 1425
StackTrace:
   在 HandyControl.Tools.Interop.InteropMethods.GetDC(HandleRef hWnd)
   在 HandyControl.Tools.WindowHelper.get_DpiX()
   在 HandyControl.Tools.WindowHelper.get_WindowResizeBorderThickness()
   在 HandyControl.Tools.WindowHelper.get_WindowMaximizedPadding()
   在 HandyControl.Controls.Window.HwndSourceHook(IntPtr hwnd, Int32 msg, IntPtr wparam, IntPtr lparam, Boolean& handled)
   在 System.Windows.Interop.HwndSource.PublicHooksFilterMessage(IntPtr hwnd, Int32 msg, IntPtr wParam, IntPtr lParam, Boolean& handled)
   在 MS.Win32.HwndWrapper.WndProc(IntPtr hwnd, Int32 msg, IntPtr wParam, IntPtr lParam, Boolean& handled)
   在 MS.Win32.HwndSubclass.DispatcherCallbackOperation(Object o)
   在 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)

版本:1.45.0 2026-07-25 23:54 Microsoft Windows NT 10.0.19045.0