Answered by:
Background task if internet is not available in windows 8.1

Question
-
I want to submit a form, once the systems gets internet option become available through background task in Windows 8.1? Please share useful inputs and thanks in advance.Tuesday, August 5, 2014 6:59 AM
Answers
-
You can use background file download system: http://msdn.microsoft.com/en-us/library/windows/apps/xaml/Hh452975(v=win.10).aspx
Just create an unique id for your form submission, and send it to your server. The server must handle, if such operation id is already done, so it will not do this operation second time and just return the success result.
- Marked as answer by Jamles HezModerator Thursday, August 14, 2014 11:15 AM
Tuesday, August 5, 2014 7:07 AM -
Hi Cynthia,
You need to set conditions for running background task, which helps it run only when appropriate. SystemTriggerType contains InternetAvailable option. You can see more from http://msdn.microsoft.com/library/windows/apps/windows.applicationmodel.background.systemtriggertype.aspx. And how to set conditions for running a background task from http://msdn.microsoft.com/en-us/library/windows/apps/xaml/Hh977057(v=win.10).aspx.
Regards,
- Marked as answer by Jamles HezModerator Thursday, August 14, 2014 11:15 AM
Tuesday, August 5, 2014 7:44 AM
All replies
-
You can use background file download system: http://msdn.microsoft.com/en-us/library/windows/apps/xaml/Hh452975(v=win.10).aspx
Just create an unique id for your form submission, and send it to your server. The server must handle, if such operation id is already done, so it will not do this operation second time and just return the success result.
- Marked as answer by Jamles HezModerator Thursday, August 14, 2014 11:15 AM
Tuesday, August 5, 2014 7:07 AM -
Hi Cynthia,
You need to set conditions for running background task, which helps it run only when appropriate. SystemTriggerType contains InternetAvailable option. You can see more from http://msdn.microsoft.com/library/windows/apps/windows.applicationmodel.background.systemtriggertype.aspx. And how to set conditions for running a background task from http://msdn.microsoft.com/en-us/library/windows/apps/xaml/Hh977057(v=win.10).aspx.
Regards,
- Marked as answer by Jamles HezModerator Thursday, August 14, 2014 11:15 AM
Tuesday, August 5, 2014 7:44 AM