Replacing desktop wallpaper / draw on the desktop
问题 I'd like to do some custom drawing to my windows desktop such that it appears to replace the desktop background (wallpaper). My first try was to get a DC for desktopListView and draw to it: IntPtr desktopDC = GetWindowDC(desktopListView); Graphics g = Graphics.FromHwnd(desktopDC); //<-- fails on out of memory error I then tried to create a NativeWindow and capture the WM_PAINT message by assigning the native window's handle to the desktop and do my own drawing, but I was unable to see any