Two ways I can think of right off hand.

1. Use your database. Create a table just for messages.

2. Probably more along the lines of what you are looking for, use the winsock control. Look in the help file under Winsock Control, then using the Winsock Cotrol for a few examples. Or you can search here or PlanetSourceCode for "CHAT"

Hope this helps.
Roger