0

I have been trying to do some reading on how to communicate best, and it appears that the way to communicate between non-related processes running code in different languages is usually through the use of "named pipes."

it seems like in C# you would normally use WCF while setting some bindings to make use of named pipes. However, in C++, should i just directly create a named pipe or is there some framework/library that I should use to create named pipes?

Also, what alternative options do I have to create events in C++ that a C# application can hear?

James Joshua Street
  • 3,259
  • 10
  • 42
  • 80

1 Answers1

1

There are a number of IPC mechanisms to choose from in Windows.

Having evaluated a number of them, its really a case of deciding which one has the least disadvantages for your use case. I've used named pipes for a C# to C++ messaging system, and I'm still not sure I made the right choice.

That said, if you are just looking at signalling events (and don't need to include state) a shared mutex might be a lightweight alternative.

EDIT: I meant to say that if you do choose named pipes you'll need to use a custom solution. Using WCF would mean reverse engineering the WCF messaging format and reimplementing it in C++.

pixelbadger
  • 1,556
  • 9
  • 24