Dear,

Some suggestions to your code

  • change f.e. Ingroup("Administrators" to (Ingroup("Administrators") <> 0)
  • you are using RedirectOutput. Use f.e. MessageBox to verify your script.
    We introduce the $info variable.
    First statement will also a MessageBox call.
  • we move your $groupshr and @homeshr to the end. First we set the mappings
    $publicshr and $appsshr.

code:

;Version 2.1 26/10/2001
CLS
IF (MessageBox("Logon script started","Kixtart Info",0,300) <> 0)
ENDIF
;RedirectOutput("c:\logfile.txt",1)
? "Welcome, @userid"
;
$info=""
$crlf=CHR(13)+CHR(10)
:checkadmin
;
IF (Ingroup("Administrators") <> 0) OR (Ingroup("Domain Admins") <> 0)
? "You are using an admin login, do not run this script with an admin login"
? "The script will now exit and stop processing"
?
$info=$info+"Admin group: skip script"
GOTO finish
ENDIF
;
;Set variables and map drives for users
;
:setupdrives
GOSUB setvariables
GOSUB mapdrives
IF (MessageBox($info,"Kixtart Info",0,300) <> 0)
ENDIF
EXIT

:setvariables
$domain = @domain
$dataserv = "infotech"
$datapath = "\\" + $dataserv + "\"
$printserv = $datapath
;
$info=$info+"domain = "+@domain+$crlf
$info=$info+"datapath = "+$datapath+$crlf
RETURN

:mapdrives
$total = Len(@primarygroup)
$off = Instr(@primarygroup,"_")
$length = $total - $off
$group= Substr(@primarygroup,$off + 1,$length)
;
$groupshr = $datapath + $group
$appsshr = $datapath + "apps"
$publicshr = $datapath + "general"
;
? "home shr is @homeshr"
? "group shr is $groupshr"
? "public shr is $publicshr"
;
$info=$info+"pr.group = "+@primarygroup+$crlf
$info=$info+"home = "+@homeshr+$crlf
$info=$info+"appsshr = "+$appsshr+$crlf
$info=$info+"publicshr = "+$publicshr+$crlf
;
USE s: "$publicshr"
IF @error = 0
? "p: is $publicshr"
$info=$info+"publicshr = mapped"+$crlf
ELSE
? "error is @error for $publicshr"
$info=$info+"publicshr = map error @error (@serror)"+$crlf
ENDIF
;
IF (Ingroup ("it_apps") <> 0)
USE r: "$appsshr"
IF @error = 0
? "r: is $appsshr"
$info=$info+"appsshr = mapped"+$crlf
ELSE
? "error is @ERROR for $appsshr"
$info=$info+"appsshr = map error @error (@serror)"+$crlf
ENDIF
ENDIF
;
IF (len(@homeshr) <> 0)
USE h: "@homeshr"
IF (@error = 0)
? "h: is @homeshr"
$info=$info+"home = mapped"+$crlf
ELSE
? "error is @error for @homeshr"
$info=$info+"home = map error @error (@serror)"+$crlf
ENDIF
ELSE
? "no h: for @homeshr"
$info=$info+"home = no mapping"+$crlf
ENDIF
;
USE t: "$groupshr"
IF @error = 0
? "t: is $groupshr"
$info=$info+"groupshr = mapped"+$crlf
ELSE
? "error is @error for $groupshr"
$info=$info+"groupshr = map error @error (@serror)"+$crlf
ENDIF
RETURN
;---------------------------------------------------------------------------
:finish
IF (MessageBox($info,"Kixtart Info",0,300) <> 0)
ENDIF
EXIT


Please let us know your result.
Please put also your logon batch file on the board.
Your error cannot execute kix32 isn't a kixtart problem, but possible
a permission problem. Verify your rights to your netlogon directory.
In your first entry you talk about the migration from netware to windows 2000. Did
your organisation also make those changes to other departments?

greetings.

_________________________
email scripting@wanadoo.nl homepage scripting@wanadoo.nl | Links | Summary of Site Site KiXforms FAQ kixtart.org library collection mirror MCA | FAQ & UDF help file UDF kixtart.org library collection mirror MCA | mirror USA | mirror europe UDF scriptlogic library collection UDFs | mirror MCA