Dave Script problem

Hello:

I am using OS 10.2.8 and DAVE 4.0 to bridge the MAC and PC. I am currently experiencing major problems with my script. Currently there are 2 scripts because 1 script just didn’t work for me.

Here is my Script:

tell application “Finder”
set USER to do shell script “whoami”
set PASS to USER
set DOMAIN to “MCLAN”
end tell

tell application “DAVE Scripting”
logon username USER with password PASS in domain DOMAIN
quit
end tell

tell application “Finder”
open location “cifs://cbq_” & DOMAIN & “/” & USER & “H”
open location “cifs://cbq
” & DOMAIN & “/IMAC_PUB”
open location “cifs://cbq_” & DOMAIN & “/Audio$”
open location “cifs://cbq_” & DOMAIN & “/Graphics$”
end tell

The problem is it would only mount the first 2 volumes and then comes up with the message “DAVE failed to mount “Audio$” Please correct the following error and try again. The $ represent the Hidden shares on the Server.

My second problem is, I save it as an application and when executed I get the following message “Could not run the script “MAC Logon script” because of a program error.”
-1376

I know this is probably not the place to ask this question but any help would be grateful…

Thank you.

To save yourself some trouble, you do not have to use Finder for what you are trying to accomplish.

try
	mount volume "cifs://server1" on server "servername" as user name "user" 
on error errmsg number errnum from errFrom partial result errResult to errTo
	display dialog errmsg
end try