How can I create a RAS Connection Script?

A. A. It is possible to write a script that will run when you connect during a RAS connection to automate actions such as entering your username and password. To specify a script perform the following

  1. Double click on My Computer and start up the Dial-up Networking applet
  2. Select the phonebook entry and click More.
  3. From the More menu select "Edit entry and modem properties"
  4. Click the Script tab and select "Run this script"
  5. Click the "Edit script..." button and the SWITCH.INF file will be opened
  6. Go to the bottom of the file and create a new connection section and then select exit
  7. Answer Yes to save changes
  8. Click the "Refresh List" button and the new entry will now be displayed.
  9. Select the new entry you created and click OK.

An example addition to the SWITCH.INF would be

; the phonebook entry
; send initial carriage return
; wait for : (after username, may be different at your site) omit the U as it may be capitals. You could just have :
; send username as entered in the connection dialog box, alternaticly you could just enter the username e.g. savillj<cr>
; wait for : (after password this time, may be different at your site)
; send the password entered in the connection dialog box, again you could just manually enter the password, e.g. password<cr>
; send the "start ppp" command
COMMAND=ppp default<cr>

In depth information on all of the commands can be found in the SWITCH.INF file.

Hide comments


  • Allowed HTML tags: <em> <strong> <blockquote> <br> <p>

Plain text

  • No HTML tags allowed.
  • Web page addresses and e-mail addresses turn into links automatically.
  • Lines and paragraphs break automatically.