Click here to Skip to main content
15,883,458 members
Please Sign up or sign in to vote.
1.00/5 (1 vote)
See more:
Hi,
I developed a Windows form application using C# & MySQL, also I know about REST API in Node.js (express) and Laravel.

I know it is different languages and may be different techniques.

but, I want to add this feature to my C# Windows form application.

In brief, I want to use C# WinForms to:
1- create a local Server-side in C#.net that accepts API requests:


2- design and code an HTTP buttons window (Client-side) to send requests to the Server-side from any device such as smartphones
http://10.0.0.1:8088/


What I have tried:

I searched on google but all I found was about sending HTTP requests to a web endpoint.
Posted
Updated 13-Jul-23 23:52pm

1 solution

It is going to be difficult to find an all-in-one solution online for your requirements.

You need to first draw up your mind-map requirements, break them down into little objects then start with creating each object accordingly.

There are many mind-maps (some free ones as well) available online - software mind map[^]

Quote:
create a local Server-side in C#.net that accepts API requests

-What is the server's function in correlation to your app
-What requests must it be able to handle
-What API will you use, what does their documentation state on allowed and dis-allowed processes
-What return is expected from the requests etc. etc.

a Full tutorial is available from MS at - Call a Web API From a .NET Client (C#)[^]

Quote:
design and code an HTTP buttons window (Client-side) to send requests to the Server-side from any device such as smartphones


The same rule applies here, first ask all of the questions, lay them out and then start your design/functionality of each page -
On mobile forms, you can get a tutorial from MS at - How To: Add Mobile Pages to Your ASP.NET Web Forms / MVC Application[^]
a Tutorial on server and framework is available at - Consume Web API By MVC In .NET Core (1), Server And Framework[^]

This should point you in the right direction.
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900