Hi and welcome to the board.

Adding drives will work like you posted it would be better to delete them before mapping them. See below. You could get in trouble with the hidden shares because kix variables start with the $ character. You might need to double up the dollar characters if you have issues with drive mappings.

 Code:
; *****************
; * DRIVE MAPPING *
; *****************

;Mapped Drive

Use Q: /delete /persistent
Use Q: "\\zeus\Photos$" 
Use O: /delete /persistent
Use O: "\\zeus\staff-pupil$" 
Use X: /delete /persistent
Use X: "\\zeus\applications" 
Use Y: /delete /persistent
Use Y: "\\zeus\%username%$" 


If InGroup("Group-Admin") 
	Use R: /delete /persistent
	Use R: "\\zeus\Reports$"
	Use W: /delete /persistent
	Use W: "\\zeus\Staffdata$" 
EndIf

If InGroup("GROUP-Intern") 
	Use W: /delete /persistent
	Use W: "\\zeus\Staffdata$" 
EndIf


A cleaner way imho would be to check if the drive exists and if it does check where it links to and fix that if needed. If the drive exists and the path is correct I skip mapping them. This is bit more advanced and it would be better to first learn to walk before trying to run.

Printers:
Adding printers is not that difficult. See the example below.
Please not that AddprinterConnection uses the printer share name and SetDefaultPrinter uses the printer name. I always make sure both names are the same just to avoid issues.

 Code:
If InGroup("SomeGroup")
	$rc = AddPrinterConnection("\\server\printersharename")
EndIf

If InGroup("Someothergroup")
	$rc = SetDefaultPrinter("Printername")
EndIf


The same as for the drive mappings is true for printers. There is a way to check if they are already installed and skip mapping them if they are already there but again, let’s start with the basics.

Wallpaper:

 Code:
$rc = SetWallpaper("pathtowallpaper\wallpaper.bmp")


And again the same is true for this. There are advanced ways of getting this done with for example a check to see if the wallpaper is up to date and copy a new one if it is not. Walk....run.....yada yada... I think you know where I'm going here ;\)

Internet and proxy settings do not belong in a login script imho. There are lots of GPO options for this so I'd suggest using a GPO for Internet Explorer and proxy settings.

I'm not sure if there is a generic logon scripts basics document because there are lots of languages that can be used. I would suggest to browse this board as much as possible and to read this: Fundamentals of programming. Glenn (a long time member of this board) made this and it was useful teaching kixtart to my colleagues and trainees. Just trying in a test setup doesn't hurt also. Yes you may crash and burn sometimes but we all did this at some point and learned from our mistakes…..hopefully


Edited by Mart (2012-02-13 09:37 AM)
Edit Reason: Fixed link to Glenn's site.
_________________________
Mart

- Chuck Norris once sold ebay to ebay on ebay.