I\'ve been trying to add an out of process background task to my project to update my App\'s live tile. The task needs to make a database call to get some data, then process
I hit the same issue. Unfortunately adding audio is not a solution as this will be a requirement for the windows store, not a good idea. Setting minimum target version gives you very limited Windows Store functionality and less UWP features.
Get started by using this link and follow it very carefully:
https://docs.microsoft.com/en-us/windows/uwp/launch-resume/create-and-register-a-background-task
To summarise:
Personally I recommend to use an out-of-process background task to eliminate any possibly that if the background task crashes it does not affect the app from running, also much more flexible.
As a tip your BackgroundTaskBuilder will reference as strings:
builder.Name = "MyBackgroundTask";
builder.TaskEntryPoint = "BackgroundTasks.MyBackgroundTask";
I find making background tasks in UWP quite tedious, but once done well worth the effort.
Thank you for the MSDN-Link since I stumbled uppon exact the same problem.
Following all the discriptions from the link helped me starting my app. I followed this stepps:
Especialy the last step seems mandatory, hope this does not conflict with your desired needs.
Setting the Minimum Target Version to 15063 in my projects fixed this error for me.
I only had to add a reference to the BackgroundTask project in the main project.
I pulled out my hair on this one too. I finally solved it by just setting the Target and Min version respectively to Fall Creators Update (build 16299) and (most crucial) the November Update (build 10586).
Side note 1 RedStone 4 release (version 1803; build 17133) is now avail at the time of writing my answer but I limited the Target version to Fall Creators (and even had to restore my development PC back to 1709; build 16299) due to too many issues with the development with my project.
Side note 2 Setting the Min version further back gave me missing functionality (like a missing System.Diagnostics.Trace symbol).