2

So i'm making a point of sales (POS) system and require communication between a WPF Client application and a ASP.NET Core application. I was initially looking to use WCF (where you would tag properties and classes with attributes and generate service references on the client-side) but i'm trying to learn ASP.NET Core. Is there an equivalent of this 'meta-data' sharing between the two endpoints? i.e. auto generate service references on client-side from classes located on server-side.

If not... what is the best way (best practice method) to:

  1. Communicate between the client and server
  2. Share meta-data between the client and server

FYI: I am also using entity framework core if you need to know

1 Answer 1

1

I would recommend a webapi rather than WCF, since it's light and easier to use. With webapi, you can generate REST client that will make your life easier, or you can fire http requests directly if you prefer.

To create a REST client, check this link: https://learn.microsoft.com/en-us/dotnet/csharp/tutorials/console-webapiclient

Sign up to request clarification or add additional context in comments.

2 Comments

Thanks a lot, got them communicating! One question though.... When using this WebApi system, I would have to create a dll that is referenced by both solutions to enable me to send models/contracts across?
your webapi will generate a dll. But the communication is not through dll directly, but through http. You'll need to host your webapi (e.g. using azure app services) and send http request against it.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.