home *** CD-ROM | disk | FTP | other *** search
-
- % -----------------------------------------------------------------------------
- % Login to a Terminate hostmode and logoff again *TERMINATE PRESCRIPTION*
- % -----------------------------------------------------------------------------
- %
- % Version : 1.00
- % Filename : LOGIN.TSL
- % Company : SerWiz Comm
- % Programmer : The Serial Wizard
- % Module created : 18 Apr 1996
- % Latest revision : 18 Apr 1996
- % Language/version : Terminate Prescription 1.00
- % Remarks : Demonstrates how to use WaitFor and Send
- %
- % -----------------------------------------------------------------------------
-
- % Dial entry 1 in the phonebook
-
- Dial 1
- If IOResult=0
- Goto NoConnect
- Endif
-
- WaitFor "Name : ",30
- If IOResult<>0
- Goto StringTimeout
- Endif
- Wait 100
- Send "bo bendtsen^M"
-
- WaitFor "Password: ",30
- If IOResult<>0
- Goto StringTimeout
- Endif
- Wait 100
- Send "secret^M"
-
- WaitFor "More (Y/n/=)",30
- If IOResult<>0
- Goto StringTimeout
- Endif
- Wait 100
- Send "n"
-
- WaitFor "Press ENTER to continue.",30
- If IOResult<>0
- Goto StringTimeout
- Endif
- Wait 100
- Send "^M"
-
- WaitFor "Enter command (Return to exit) : ",30
- If IOResult<>0
- Goto StringTimeout
- Endif
- Wait 100
- Send "g"
-
- WaitFor "Say goodbye (y/N): ",30
- If IOResult<>0
- Goto StringTimeout
- Endif
- Wait 100
- Send "y"
-
- Hangup
- Goto End
-
- :StringTimeout
- ClearScreen
- PrintLn "Script timed out waiting for string"
- Goto End
-
- :NoConnect
- PrintLn "Connection aborted"
- Hangup
- Goto End
-
- :End
-
-