By registering with us, you'll be able to discuss, share and exchange private messages with other members of our community.

SignUp Now!


Can you be more specific about what you want the script to do? ... simply collect information? ... something more than that?
My email account is at panix.com (I buy my IP from Cablevision). I Telnet to panix for interaction. This involves the Telnet command and when panix answers I have to type in my name. They then ask for my password. I want to create one command that Telnets, waits for the answer, sends my name, and then waits for a reply, and finally sends my password. And then disappears leaving me connected for further interaction. Back in CP/M-80 days there was a small programlet that you ran and it enabled you to interact with batch files. DOS never had (as far as I know) anything like that. The CP/M thingie was part of Kildahl's original version; not the ZCPR extensions.
The first think that comes to mind is rather crude.

In TCC, use the KEYSTACK command to schedule the keystrokes of your userid and password after appropriate delays, and then start TELNET.EXE.

As far as I know, Kermit95 still exists. With it, you can script telnet sessions. It's not free.
Some more constraints - I do not use TC; only TCC. Kermit 95 is a graphical program and not at all what I want. I do have a way of scripting Telnet commands - my Emacs-like editor (Epsilonc) is quite capable of doing that with built-in Telnet. The problem with that is that I want to end up at a command prompt and there is no easy way to scriptedly get out of Epsilon and drop into the command prompt.
IIRC, Kermit95 also had a console mode. Doesn't it go without saying that after you do a telnet login, you're in a terminal emulator of some kind and with a command interpreter, namely the remote shell?

It's not terribly clear what you want to do ... have a telnet session and a local command prompt running in the same console and be able to switch between them? TCC (not TC) can use alternate console screen buffers (see @CONSOLEB) but if telnet were running in one of them, I don't know how you'd get out of telnet.
IIUC, you want to automate internet connection?
I'm 99% sure that everything you want to do has been automated in the last century and readily available in the OS itself.