I'm attempting to develop an Xbox Game Bar Widget, which obviously needs to be UWP. I need it to communicate with my separate unpackaged desktop app. The regular desktop app has to be unpackaged because it requires admin rights in order to read CPU temperatures.
I've tried using Named Pipes as the Microsoft Docs page suggests, but I'm having issues creating/connecting the pipes on the UWP side. I just keep getting Access Denied exceptions. I've had trouble finding information/examples on interprocess communication between UWP and unpackaged apps. Any direction / advice is much appreciated.
Related
I have a uwp project and a windows app (net5).
Both are installed in the same machine (same will happen in production), but the uwp is installed using sideloading, not on windows store.
The windows app gets some data by listening to a wss port. I have to pass those data from the windows app to the uwp app and also wait for a response back from it.
To do this internal communication I came across the AppServiceBridgeSamples in this repo https://github.com/microsoft/DesktopBridgeToUWP-Samples but it is outdated and I can't use it.
Is there any alternatives to it? What would be the easiest implementation to achieve this?
Any suggestions/comments are appreciated.
Currently, the general way to implement a communication channel between a UWP app and a windows app is by using App service. This is not outdated. If you don't want to use the App service, you have to build your own socket server so that both of your apps could communicate with it. Another way is that your windows app could save the data in a local file and load them in the UWP app.
I want to develop a (Universal Windows Platform) UWP app that will run locally. But another requirement is that 2 or more of the same UWP apps will be on another PC as a client. In the same local network, the database will be using sharing across all devices.
And of course, authentication and authorization will be needed on my UWP App.
I've done those in Web Apps using supported libraries according to the used language. But no idea how to implement it in UWP and local-network applications.
I've targeted to use UWP C# and MySQL database.
What would be the architecture of the App and popular tech stack to use because I'm not familiar with the C# world? Thank you very much.
I have a UWP app and Unity3d app build for Windows. I have a requirement of establishing communication between UWP app and Unity3d app.Both apps will run on same computer.
Development of Unity3d app and Universal app(Windows 10 native app) both are done in C# language.
Communication should involve:
Launching and closing Unity3d app from UWP app.
Send data from UWP app to Unity3d app.
Receive data from Unity3d app to Windows native app.
I had searched for resources for this but unable to find any. Could someone please share possible ways to achieve the above and resources/examples for those.
Thanks :)
i did this via an Appservice: https://msdn.microsoft.com/en-us/windows/uwp/launch-resume/how-to-create-and-consume-an-app-service in your normal xaml app host the app service and let unity consume data from it.
And via protocol activation the apps can start eachother.
I would like to add/start/stop/remove an application (IoT Core) just like the web interface or the Power Shell commands: "IotStartup" but from within a C# application running on the IoT Core itself.
Is there a c# API for this or do I have to implement the Power Shell commands inside my application?
Using the Device Portal API could work for you.
Here are the docs.
https://learn.microsoft.com/en-us/windows/uwp/debug-test-perf/device-portal-api-core
Device Portal APIs are intended for remote management, and may not work from within a UWP against localhost due to loopback restrictions in Windows (to prevent an app from attacking the device it's running on).
That said, the Windows.Management.Deployment.PackageManager class provides installation and removal APIs for apps. To launch an app, you can use Windows.System.Launcher. Note that PackageManager is a restricted capability, so the app won't be able to go into the Store without special permissions from Microsoft. It will work in sideloaded scenarios though.
There is no way to close an app from another app with existing APIs. However, Launching the app using the above, then connecting with an AppServiceConnection to manage it, you can send a "Close" message over the AppServiceConnection that causes the app to close itself.
I have a Windows form desktop application developed using c#. I want to make use of the live tile feature available in WinRT apps (especially for Windows 10). The data in the live tile is to be fetched using WMI queries (Win32_LogicalDisk).
How do I accomplish this? I don't want to rewrite the entire app. Live tiles should update on the background and on clicking the tile, my desktop app exe needs to be invoked. Is it possible to fetch WMI data and invoke exe from Windows Store apps?
I tried using Brokered Windows Runtime components as given in http://blogs.msdn.com/b/dmx/archive/2014/04/30/how-to-trigger-a-desktop-process-from-windows-store-apps-the-easy-way-using-the-brand-new-visual-studio-templates.aspx . But could not get it to work as I get a 'TypeLoadException'.
Thanks in advance.
Metro app can't run a desktop app. However, they can commumicate using wcf. So, you can create tiny windows service that will open wcf host. Then you create windows store app with your live tile(s). When windows service recieves a wcf call, it starts the desktop application.
There is also devexpress' solution that is capable of adding live tiles for desktop apps, however it is not free: https://www.devexpress.com/Products/NET/Controls/WinForms/Live-Tile-Manager/
WinRT blocks network loopback so wcf won't work. You can disable this for testing but I suspect that won't satisfy you. Read more here (and search for WinRT network loopback to find articles on this topic).
https://msdn.microsoft.com/en-us/library/windows/apps/Hh780593.aspx