Socket connection lost (Connected = false)

C

Christian

Hi all,


i try to write a website which should dynamically show
statusinformation of the user which are using it.
Another server provides the information over TCP (plain text api).

In the codebehind file i create a thread which connects to the server
and store it as a session variable...
The first time it works, after the function fails (recieve timeout)
the property connected is false ...

Does somebody have an idea ?
I need to recieve events from that server and then i need to reload
the page...


Does somebody have an idea ?



Kind regards


Christian
 
K

Kevin Spencer

When the page is returned to the browser, the Page class is released from
memory, but not the Thread. Rather than using this method, I would suggest
that you create a Web Service that maintains a constant connection to the
server, and can provide the information to the various instances of the Page
by request.

--
HTH,

Kevin Spencer
Microsoft MVP

DSI PrintManager, Miradyne Component Libraries:
http://www.miradyne.net
 
C

Christian

Hi Kevin,


thanks for your help... I figured out, that this only happens if the
socket.recieve returns on timeout ...

I already thaougt on catching the data external ...

How can i communicate with the webservice ?
Is there a "simple" way ?
What advantages has a websevice ?



Kind regards


Christian
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Similar Threads


Members online

Forum statistics

Threads
473,769
Messages
2,569,582
Members
45,057
Latest member
KetoBeezACVGummies

Latest Threads

Top