10 FUNCTION LONG EXT_FT_MENU !====================================================================== !PROGRAM---------------------VERSION-------------------LANGUAGE-------- !EXT_FT_MENU 2 BASIC ! !DESCRIPTION----------------------------------------------------------- !Performs file transfer menu selection. !Menu displays protocals the current user is allowed to access. !When user selects a protocal, the appropriate subroutine is launched. ! !====================================================================== %TITLE "EXTERNAL File transfer Menu Driver" %IDENT "EXT_FT_MENU 92.11.02" %SBTTL "DOCUMENTATION SECTION" !********************************************************************** ! OPTIONS !********************************************************************** OPTION TYPE = EXPLICIT ! Explicit declarations only 100 !********************************************************************** ! DOCUMENTATION SECTION !********************************************************************** ! !====================================================================== ! MODIFICATION HISTORY !====================================================================== !VERSION--------AUTHOR------------------DATE------------APPROVAL------- ! 1 John Post 91.01.01 E102ISD_0_21 ! 2 Keith Walker 92.11.02 E102ISD_0_30 ! !====================================================================== ! COMPILE/LINK/INSTALL INSTRUCTIONS !====================================================================== !$BASIC EXT_FT_MENU !$LINK 102900,- ! EXT_READ_PORT_AST, EXT_UNSOL_MBX_AST,- ! EXT_PROC_BUF_AST, EXT_WRITE_TERM_AST,- ! EXT_SCRIPT_INTERP, EXT_SCREEN_HDR,- ! EXT_MENU, EXT_CONNECT_LOOP, EXT_PARSE,- ! CHKRGHTS, EXT_FT_MENU, XMODEM !====================================================================== !********************************************************************** ! FILES ACCESSED !********************************************************************** ! NAME MODE CHANNEL DESCRIPTION !-------------- ------ ------- ------------------------------- !LF_MENU READ MENU_FILE menu file !LF_PORTS READ PORTS_FILE port selection file ! !********************************************************************** %PAGE %SBTTL "DECLARATION SECTION" 200 !====================================================================== ! DECLARATION SECTION !====================================================================== !********************************************************************** ! %INCLUDE FILE DECLARATIONS !********************************************************************** %INCLUDE "EXT_COMMON.BAS" !********************************************************************** ! CONSTANTS !********************************************************************** !********************************************************************** ! RECORDS !********************************************************************** !********************************************************************** ! MAPS !********************************************************************** !********************************************************************** ! COMMONS !********************************************************************** !********************************************************************** ! VARIABLES !********************************************************************** DECLARE LONG & FUNC_STAT !status from function DECLARE STRING & CHOICE !********************************************************************** ! ARRAYS !********************************************************************** !********************************************************************** ! FUNCTIONS !********************************************************************** !********************************************************************** ! EXTERNAL CONSTANTS !********************************************************************** EXTERNAL LONG CONSTANT & SS$_NORMAL !********************************************************************** ! EXTERNAL FUNCTIONS !********************************************************************** !********************************************************************** ! EXTERNAL SUBPROGRAMS !********************************************************************** EXTERNAL SUB & EXT_SCREEN_HDR %PAGE %SBTTL "INITIALIZATION SECTION" 300 !====================================================================== ! INITIALIZATION SECTION !====================================================================== ON ERROR GOTO ERROR_HANDLING !********************************************************************** ! PRINT USING FORMATS !********************************************************************** !********************************************************************** ! VARIABLES !********************************************************************** FUNC_STAT = SS$_NORMAL %PAGE %SBTTL "MAIN LOGIC SECTION" 1000 !====================================================================== ! MAIN LOGIC SECTION !====================================================================== CHOICE = "" WHILE EDIT$(CHOICE, 32) <> "E" PRINT CHR$(27);"[2J";CHR$(27);"[1;1H" PRINT " Select a File Transfer Protocol" PRINT PRINT " 1. KERMIT" PRINT " 2. XMODEM" PRINT " E. Exit from this menu" PRINT PRINT SET NO PROMPT INPUT " Enter Choice: ";CHOICE SELECT CHOICE CASE "1" PRINT PRINT "Sorry, Kermit is not yet available." PRINT INPUT "Press RETURN to contine...", CHOICE CASE "2" CALL XMODEM CASE "E","e" !do nothing; just exit CASE ELSE PRINT "That is not a valid choice." PRINT "" INPUT "Press RETURN to continue..."; CHOICE END SELECT NEXT GOTO END_OF_PROGRAM %PAGE %SBTTL "SUBROUTINE DEFINITION SECTION" 15000 !====================================================================== ! SUBROUTINE DEFINITION SECTION !====================================================================== %PAGE %SBTTL "FUNCTION DEFINITION SECTION" 20000 !====================================================================== ! FUNCTION DEFINITION SECTION !====================================================================== %PAGE %SBTTL "ERROR HANDLING SECTION" 25000 !====================================================================== ! ERROR HANDLING SECTION !====================================================================== ERROR_HANDLING: ON ERROR GOTO 0 !====================================================================== ! END OF PROGRAM !====================================================================== END_OF_PROGRAM: EXIT FUNCTION FUNC_STAT 29999 END FUNCTION