r/WPDev • • Jun 25 '18
An app to create a Dynamic wallpaper effect on Windows 10 Devices. Help needed
I never had anything to do with programming before, but I had an idea for a UWP app that schedule applied wallpaper on windows 10. I thought it would be a good project to learn C#.
I have started with some basic functions (adding an image and a timer to apply the image) you can find it on GitHub.
Of course I was not the first who had an idea like that. Samuel Carreira, Timothy Johnson and Divit Sharma all had similar concepts, but each with different approaches limitation.
The step I am stuck at which I need help with is: First, a way to make a List of the added Images with the Times to be applied as wallpaper or lockscreen. Second, a way to use this list in a background task! Third, display all the images added with their times of display in a Grid view with an option to remove each of them.

2
u/colinkiama Jun 30 '18 edited Jun 30 '18
(Related to the second step) From what I see, you are using async code in BackgroundClass.cs but there isn't a deferral being used. (Which will cause problems with the background task).
This is how you would add deferrals:
2
u/colinkiama Jun 30 '18
I opened a pull request on GitHub which does step 1 and 2. It also fixes a lot of the bugs that have been causing the app to crash. It's here: https://github.com/moutasem1989/ActiveDynamicWall/pull/1
1
u/[deleted] Jun 27 '18
So i have done this by seeing what others did to get tome functions to work .. but i have no idea why it is not working! As I mentioned .. I am just a beginner here !
1
u/[deleted] Jul 01 '18
Thanks to colinkiama, the app now works as it should! I really appreciate your contraptions
I want to add a settings option to the app (set wallpaper to desktop/to lockscreen).
//Settings to be applied to lockscreen and Desktop - still needs workprivate void ApplyToLockscreen(object sender, RoutedEventArgs e){Windows.Storage.ApplicationDataContainer localSettings = Windows.Storage.ApplicationData.Current.LocalSettings;localSettings.Values["applyLockscreen"] = "checked";}private void NotApplyToLockscreen(object sender, RoutedEventArgs e){Windows.Storage.ApplicationDataContainer localSettings = Windows.Storage.ApplicationData.Current.LocalSettings;localSettings.Values["applyLockscreen"] = "unchecked";}private void ApplyToDesktop(object sender, RoutedEventArgs e){Windows.Storage.ApplicationDataContainer localSettings = Windows.Storage.ApplicationData.Current.LocalSettings;localSettings.Values["applyDesktop"] = "checked";}private void NotApplyToDesktop(object sender, RoutedEventArgs e){Windows.Storage.ApplicationDataContainer localSettings = Windows.Storage.ApplicationData.Current.LocalSettings;localSettings.Values["applyDesktop"] = "unchecked";}How can I transfer those settings into something usable in the background task?
I am also working on another function in the app. A way to use Image sequences that shift between day and night and are applied based on the local sunrise/sunset times and the time of the day. I started with the location class and the Sunrisesunset API.
1
u/[deleted] Jul 05 '18
When trying to debug the app for ARM I get an error msg:
there are some fixes online but none of them worked for me .. do you have a working fix?
1
u/colinkiama Jun 30 '18 edited Jun 30 '18
Also looking into this. The design looks really nice so far by the way š
3
u/imthewiseguy Jun 25 '18
Iām gonna type up some code when I get home and let you know what I find