Applescript Telnet Frontend

I am going to preface this by saying I am an Applescript newbie. I have thrown together a bunch of graphical Applescript apps ever since OSX came out using bits and pieces of things from this site, and naturally some of it sunk in. Regardless, I lack a general understanding of how the Applescript interface works, but I like the simplicity of developing GUI apps for OSX using it (I can’t be bothered to learn Cocoa, Carbon). Regardless, I am an experienced C++ Linux developer, if that even matters.

Anyway, what I hope to do this time is create an Applescript Studio application that creates a frontend for Telnet. Now, the application is going to have a particular theme being POP3 access. I want to be able to have, for example, a text box with the mail server IP or hostname, and the username and password of a user. Then I could do something like

do shell script “telnet " & mailserver & " 110”

To telnet into the mail server. Unfortunately, my applescript knowledge stops me at that point. I have no idea how I would then send the commands to the mail server and see the subsequent output (put it in a large text box in the Applescript GUI). So, how is it that I can send commands to an already open “shell script” or program? Right now I am totally lost in between Apple’s documentation and some example scripts that don’t seem to be doing the same thing that I want. :frowning:

Any help would be greatly appreciated; thanks in advance.

Demon 0

Demon,

As far as I know “do shell script” is only good for commands that return a value, not a user-operated program.

If I’m wrong, I’m sure someone else will chime in, but that’s my understanding. I’ve used it to get man pages and display them in a window, but that (again) is a situation where you do the shell command and get back a block of text.