-1

App1 send a request and wait for app2 to give a reply (true/false) or request time out.

How to do this using c# and wcf.

I managed to send the request but i dont know how to wait and make app2 give a reply

  • i'm sorry, my code is in this [post](https://stackoverflow.com/questions/51396622/publish-a-message-and-wait-until-replied-or-time-out) – Michael_123456789 Jul 20 '18 at 06:14

2 Answers2

0

You can use tpl. The library has wait, continue ... methods. You can find docs easily by searching on google.

dcy
  • 35
  • 7
0
  1. Create WCF application project in Visual Stuio.
  2. Project must contains file *.svc, put your method to this file, add contract attributes.
  3. Run WCF application, by default browser open new tab with your application url
  4. Choose in browser file *.svc and copy (f.e http://localhost:32490/nameOfProject.svc)
  5. In second application click on projcect in solution explorer(not solution), choose add service reference
  6. put link from step 4, and visual studio generate environment with client classes.
  7. to call method on client create instance of {NameOfYourApplication}ServiceClient class from step 6.
Fedor
  • 181
  • 5