简体   繁体   English

如何完全运行UWP应用程序背景

[英]How to run a UWP app background completely

I have developed a UWP application service which called from a WinForms application. 我开发了一个从WinForms应用程序调用的UWP 应用程序服务

So, when the WinForms application is executed, I want to run the UWP application service in the background, preferably launched hidden. 因此,当执行WinForms应用程序时,我想在后台运行UWP应用程序服务,最好是启动隐藏。

How do I launch the hidden UWP application in the background? 如何在后台启动隐藏的UWP应用程序?

It is not possible to run UWP apps in background like windows services run. 无法在Windows服务运行等后台运行UWP应用程序。 They execute in a sandbox environment and has a sophisticated pattern of execution. 它们在沙箱环境中执行,并具有复杂的执行模式。 You can't hide their launch, however you can run some logic of your application in background to facilitate your application like providing live tile updates, receive push notifications etc, even when your app is not running. 你无法隐藏他们的发布,但是你可以在后台运行你的应用程序的一些逻辑,以方便你的应用程序,如提供实时磁贴更新,接收推送通知等,即使你的应用程序没有运行。 For that you can read this article Create and register a background task and watch this video from channel 9. 为此您可以阅读本文创建并注册后台任务并从第9频道观看视频。

This is possible via the iot Background App template. 这可以通过iot Background App模板实现。 You will need to have embedded mode enabled and running wherever you want to run the app, though. 但是,您需要启用嵌入模式并在运行应用程序的任何位置运行。

Read more here. 在这里阅读更多

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM