And I am struggling somewhat. I started off using System.Net.Sockets.Socket and it didn't seem to do what it said on the tin. Since then I've moved on to using the TcpClient mechanism which is allegedly simpler.
I seem to be having timing issues with my wannabe telnet client. The stuff I've written works fine when I step through it, but when I let it run through on it's own, I get problems where it seems to run too fast and doesn't allow time to receive the data back from the server, despite using what I thought were blocking functions.
i.e. I expect the following from the server:
When I step through, I get that fine in my return string. But when left to run, I only get the first line, so the stuff that relies on waiting for "Username: " always comes back as false.
I don't know how to work around it. My Google-fu is failing me and it's frustrating as 'owt.
Anyhow. Tomorrow is another day, and the brain may be more awake.
I seem to be having timing issues with my wannabe telnet client. The stuff I've written works fine when I step through it, but when I let it run through on it's own, I get problems where it seems to run too fast and doesn't allow time to receive the data back from the server, despite using what I thought were blocking functions.
i.e. I expect the following from the server:
Welcome to XYZ telnet server Username:
When I step through, I get that fine in my return string. But when left to run, I only get the first line, so the stuff that relies on waiting for "Username: " always comes back as false.
I don't know how to work around it. My Google-fu is failing me and it's frustrating as 'owt.
Anyhow. Tomorrow is another day, and the brain may be more awake.
There are 8 comments on this entry. (Reply.)