Q

How do I create an instant messaging ASP.NET application?

How do I create an instant messaging ASP.NET application? I thought using threading, tcpclient and tcplistener namespace and invoking to update the textbox would work, but I tried and it's not working. Any guidelines are appreciated.
Are you trying to develop the server application, the client application (inside a browser) or both? If you want to develop both, you should use plain JavaScript and HTML and poll the server for new messages every couple seconds from the client, either refreshing an IFrame or querying with the XMLHttpTranser object. The server should be implemented as an IHttpHandler to be fast and avoid most of the ASP.NET Page Framework overhead, which is not necessary. You'd have storage for the most recent messages (maybe in-memory, maybe a database) and return that on the IHttpHandler.ProcessRequest method. If the client is refreshing an IFrame, if may be easier to have an aspx page returning the messages.
This was first published in July 2004

Dig deeper on Win Development Resources

Have a question for an expert?

Please add a title for your question

Get answers from a TechTarget expert on whatever's puzzling you.

You will be able to add details on the next page.

0 comments

Oldest 

Forgot Password?

No problem! Submit your e-mail address below. We'll send you an email containing your password.

Your password has been sent to:

-ADS BY GOOGLE

SearchCloudComputing

SearchSoftwareQuality

SearchSOA

TheServerSide

SearchCloudApplications

Close