Hey, I'm currently working on a social network website in ASP.NET, C#. I want to know the steps to create a chat application.
Kindly guide me,
Thanks.
As suggested remoting, note that .NET Remoting is a legacy .NET-to-.NET technique and is not a good fit for browser-based chat. For an ASP.NET/C# site a much simpler and more robust approach is SignalR (it uses WebSockets when available and falls back to other techniques automatically) or, if you prefer lower-level control, plain WebSockets for browsers.
Practical starting steps
Minimal example (concept only)
public class ChatHub : Hub
{
public Task SendMessage(string user, string message)
{
return Clients.All.SendAsync("ReceiveMessage", user, message);
}
} const conn = new signalR.HubConnectionBuilder().withUrl("/chatHub").build();
conn.on("ReceiveMessage", (user, msg) => { /* update UI */ });
await conn.start();
await conn.invoke("SendMessage", user, message); Quick cautions and troubleshooting
Official docs: ASP.NET Core SignalR introduction and the browser WebSocket reference at MDN WebSocket API.
Jump to Post— Topi Ojala 2I suggest Client and Server classes with remoting.
I suggest Client and Server classes with remoting.
How do I start it?
We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.