PROC choose_network_type (
  network_type: var of string
  status)

  create_variable choice k=string

main_loop: ..
  LOOP

    put_line ('1Choose Network Type'..
          '01. Define Channel Network (Mainframe to DI across Cyber channel) ' ..
          ' 2. Define ICA Access (Mainframe connection to network using an ICA) ' ..
          '0Enter a menu selection, QUIT, ?: ')

    choice = ' '
    accept_line choice input p=''

  IF choice = '1' THEN
    $value(network_type) = 'DEFINE_CHANNEL_NETWORK'
    EXIT main_loop
  ELSEIF choice = '2' THEN
    $value(network_type) = 'DEFINE_ICA_ACCESS'
    EXIT main_loop
  ELSEIF ($translate(lower_to_upper, choice) = 'QUIT') OR ($translate(lower_to_upper, choice) = 'QUI') THEN
    $value(network_type) = ' '
    EXIT main_loop
  ELSEIF choice = ' ' THEN
      " Do nothing if the user types-ahead."
  ELSEIF choice = '?' or ($translate(lower_to_upper, choice) = 'HELP') THEN

      put_line (..
            '0This menu prompts you to choose the type of network configuration ' ..
            ' on your mainframe. ' ..
            '01.  Select number 1 if your mainframe is connected to a CDCNET ' ..
            '     DI via a CYBER channel. '..
            '02.  Select number 2 if your mainframe is connected to the network ' ..
            '     via  an ICA.' ..
            '0Enter QUIT to return to the main menu without choosing a network ' ..
            '   type. '..
            '  ')
      accept_line choice input p='Press NEXT: '
  IFEND
  LOOPEND main_loop

PROCEND choose_network_type
