I need to show a Message box for user with two buttons(open application, cancel) when an application is in background. How can I realise it (should it be a background task) ?
You can't show custom message box from background.
As a workaround you can show Toast Notification
from Background Agent
. Look at ShellToast
, it's made for this purpose. When toast appears, users can tap it to open application as you need.
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.