MS Edge Extension with Native Messaging on Desktop PC - Run UWP App in Background / no UI
As Microsoft Edge is a Universal Windows Platform Application it only supports communicating with another UWP App via AppService (and further communicating with our classic desktop application via FullTrustProcess). Our classic desktop app cannot be converted to an UWP app for many reasons. Basically this is no problem, but there are some issues I currently don't know how to solve:
UWP Apps seem to require a user interface. But the extension's purpose is only the communication, there is no UI intended.
Is there any way to send the UWP App to background mode execution instead of termination if the user closes the UI of the App? So that the App can continue running in background mode as it did before?
Or is there any way to hide the UI in the OnLaunched event (e.g. then our classic desktop app will be opened, and the user will now not be able to manually close the UWP app any more)?
Probably I can find the HWND of the UWP app from our native desktop app and perform some ugly hacks with it, but I definitely want to avoid this.
I have found out, that there is a way to narrow the user's possibility to launch the application by setting AppListEntry="none" in the manifest. So the user cannot start the application from menu anymore.
But the user still can launch the application e.g. by klicking the "Launch" button after installing the app (e.g. side loaded from the appx package).
Kuldeep Desai commented
Hi, We developed something very similar recently. We have the UWP running always, but instead of console app, I am using windows app, and that will automatically run UWP in background and no UI. If there is no need for your user to view UI, you can run something similar, else if that is not the case you can subscribe to disconnect event and show appropriate message to user to run the extension again.
Hi Dominik, I have nothing to share about the solution to your problem.
We are trying to develop something similar to your extension design and want to support windows 10 anniversary edition. So, want to know if you were able to deploy the native messaging extension on windows 10 anniversary update (version 1607) or only after windows 10 creators update ??