connecting to server

how would you automate connecting to a specific IP (Connect to Server) and logging in with a particular name and password?

Try

mount volume “ip_address” as user name “username” with password “password

If an IP Address like “afp://192.168.1.101/” is used alone (for an OS 9 server, at least), you will get a dialog asking for a selection of the volume name. Better to avoid that by using an address like: “afp://192.168.1.101/My_Volume_Name” exactly as it would appear if you used the “Connect to Server” command in the Finder’s “Go” menu.