Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Running scripts on Win98 login

Status
Not open for further replies.

kdeans

IS-IT--Management
Apr 3, 2000
129
0
0
CA
The following line will work for NT/2000/XP to map a user's S: to a directory bearing the same name as their logon ID.

@net use S: \\servername\sharename\data\users\%username%

I run into two problems when I attempt to accomplish the same thing with a win98 computer (we still have 40 or so). I can branch the script based on operating system but I can't find the right syntax to get the same mapping for a user logging on to win98.

First, I cannot map beyond the share name. The example above lets non-win98 users map a few levels down the tree from the actual share.

Secondly, I am unable to use a variable to specify the user ID as the directory name or share that I want to map to. I am unable to find a list of variables that win98 will recognize. These are not home directories.

Does anyone have any ideas?
 
@echo off
net use s: /d
net use s: \\servername\sharename\data\users\%username%

if that doesn't work, load the windows scripting host (WSH) onto the 98 machines. Try vbs scripting. marcdmac has written an excellent faq on a vbs logon script in the VBScript forem.

A+/MCP/MCSE/MCDBA
 
Thanks Seaspray0.

kdeans, the FAQ referenced above is faq329-5798.

I think that you will find VBScript a lot more powerful to use. Having the 98 clients will be a pain for you though. Make sure that in addition to WSH 5.6 you also install WMI Core and DSClient software.

The 98 machines will not be GPO aware, so you will need ot place a copy of the scripts in the netlogon share in order for them to work on those machines. Not an ideal situation but what can you do, it is an 8 year old OS. ;-)

I hope you find this post helpful.

Regards,

Mark
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top