private static void UpdateWallpaper() { var myPicturesPath = Environment.GetFolderPath(Environment.SpecialFolder.MyPictures); var temporaryPath = Path.Combine(myPicturesPath, "Himawari8", "earth.png"); var image = new Himawari8Image(); image.Save(temporaryPath); image.Dispose(); if (image.SucceededDownloading) { Wallpaper.Set(temporaryPath, WallpaperStyle.Centered); } }
private static void UpdateWallpaper() { var myPicturesPath = Environment.GetFolderPath(Environment.SpecialFolder.MyPictures); var temporaryPath = Path.Combine(myPicturesPath, "Himawari8", "earth.png"); var image = new Himawari8Image(); image.Save(temporaryPath); image.Dispose(); if (image.SucceededDownloading) { Wallpaper.Set(temporaryPath, WallpaperStyle.Centered); } }