Scripting RA in OS 9.2
Scripting RA in OS 9.2
- Subject: Scripting RA in OS 9.2
- From: Jim Good <email@hidden>
- Date: Tue, 16 Oct 2001 13:44:36 -0500
As of OS 9.1 (I'm using 9.2) you can't script Remote Access. Instead,
you script Network Setup Scripting (in the Scripting Additions
folder) to control Remote Access. But I've run into a problem. I
downloaded two scripts from Apple, one to connect via RA and one to
disconnect. However, I also want it to be able to select one of two
RA configurations (Earthlink and my Rice U configuration). The script
I downloaded is supposed to do just that (see below), but it's not
working. It just connects via whatever happens to be the currently
active RA configuration. Can someone tell me how to make this work?
This is the script I got from Apple's AppleScript website. All I did
was substitute the name of my RA configuration, "Earthlink."
-------
set the config_name to "Earthlink"
try
tell application "Network Setup Scripting"
--open the Networking Database
open database
--start the connection process
connect Remote Access configuration config_name
--close the Network Database
close database
end tell
on error
try
--close the database if it was left open
tell application "Network Setup Scripting" to close database
end try
end try
-------
TIA,
Jim