C#: Set Desktop Wallpaper to a Solid Color

前端 未结 1 1283
一个人的身影
一个人的身影 2021-01-19 20:52

I\'m using this code to remove the current wallpaper and set a solid color:

public static class WallpaperColorChanger
{

    public static void SetColor(Colo         


        
相关标签:
1条回答
  • 2021-01-19 21:10

    From memory (Been a while since I did anything like this), if you set the desktop wallpaper to NOTHING (Empty string), then set it to a file (Can be a transparent pixel if you like, then set it to nothing again, I believe that it disables the slideshow.

    You can then just set a desktop colour, and it should stick. As for program turning off the wallpaper slideshow I've no idea what the win api call for that is.

    0 讨论(0)
提交回复
热议问题