home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
OS/2 Shareware BBS: 3 Comm
/
03-Comm.zip
/
TE2HOST.ZIP
/
ACTN_99.SCR
< prev
next >
Wrap
Text File
|
1990-12-27
|
1KB
|
56 lines
global string CmdStack
global integer MenuLevel
global integer MLevelMain
global integer MLevelFile
global integer MLevelMail
global integer MLevelProto
global integer MLevelSysop
integer mch
integer retcode
;; ------------------------------------------------------------------------
;; Let the user shell out to an OS/2 command prompt. rshell() is set here
;; to echo remote characters, translate cr's to cr-lf's, perform
;; backspace translation, and watch for loss of carrier.
subroutine ShellOut
transmit("^[[2JType EXIT to return to TE/2 Host.^M^J")
message("^M^JUser is in OS/2 shell..")
retcode = rshell("cmd.exe", "", 0x0f)
transmit("^M^JWelcome back!")
transmit("^M^JPress any key to continue...")
rgetc(30, 1)
CmdStack = ""
endsub
program
mch = asciival(toupper(CmdStack))
CmdStack = strtrim(substr(CmdStack, 1, 255))
if mch == 'S'
gosub ShellOut
elseif mch == 'E'
run("notimpl.scr")
elseif mch == 'C'
run("chdir.scr")
elseif mch == 'M'
MenuLevel = MLevelMain
elseif mch == 'F'
MenuLevel = MLevelFile
elseif mch == 'R'
run("notimpl.scr")
elseif mch == 'G'
run("goodbye.scr")
else
transmit("^G")
CmdStack = ""
endif
end