2

I have been struggling with this for over a month, but am slowly learning. Here is what I have:

C# Solution With 3 Projects

-Universal Windows Platform App (Cortana Voice Support)
::Above just shows a floating PNG image and is Cortana enabled

-Universal Windows Service (Cortana Background Service)
::Needed for the Cortana Support

-.Net 4.5 C# App with HTML DOM Automation
::Automates locating elements and clicking of a website

I can't re-code my .Net app's functionality in my Universal app because some of the libraries it uses won't install. (GhostDriver, PhantomJS, and a HotKey Library provided via NuGet. Installing on the Universal Platform fails on all 3 libraries).

What is needed:

-Master Universal Windows App or Service sends signal to .Net App 

-.Net App receives signal and calls method/function providing my functionality.

I've never tried calling methods in other apps within the same solution and was wondering if there was a few-code workaround. What I need I think is a method of inter process communication or events, but can't find any examples of a UWP. Most are .Net communicating with other older non universal apps.

Thank you so much!

CREW
  • 926
  • 3
  • 17
  • 32
  • Universal apps can use WCF I am pretty sure. Just make the .NET app a WCF host and the universal apps as WCF clients. – Scott Chamberlain Oct 15 '15 at 05:19
  • WCF works, but you won't be able to use WCF from a UWP app to a localhost service without an exception put in place which is only intended for development purposes. An app distributed in the store won't get this exception unless the user explicitly applies it, and it probably won't get through store validation if it requires that exception to function. You'd need to use an intermediate remote server hosting the service. – Andrew Pilley Oct 15 '15 at 17:53

1 Answers1

3

If I understand correctly, you were developing a app which will can automate the DOM operation through Cortana.

Do you need to submit this app to App Store?

If no, as Scott said, you can use WCF to communicate between UWP process and .NET 4.5 desktop app process.

If yes, as Andrew pointed out, you need an intermediate remote server hosting the service. enter image description here

Jeffrey Chen
  • 4,650
  • 1
  • 18
  • 22