Getting Win98 to map drives based upon Group Membership 
Author Message
 Getting Win98 to map drives based upon Group Membership

This is part of the login script that I ahve running:
If sPath = "*" Or sUNCPath = "*" Then
  sAdsPath = g_oNet.UserDomain & "/" & g_oNet.UserName
  Set oAdsObj = GetObject("WinNT://" & sAdsPath & "user")
  If sPath = "*" Then sPath = oAdsObj.HomeDirDrive
  If sUNCPath = "*" Then sUNCPath = oAdsObj.HomeDirectory
  Set oAdsOBJ = Nothing
 End If
I have winNT and win98 users logging in the WinNt users work fine but win98
users are not working. Is there a way to get the users homedir info for win
98??

Marc Hayes



Sun, 13 Apr 2003 03:00:00 GMT  
 Getting Win98 to map drives based upon Group Membership

Q188602 - INFO: UserDomain Method Does Not Work Under Win95 with WSH
http://support.microsoft.com/support/kb/articles/Q188/6/02.ASP

The above also applies to Win98...

--
Michael Harris
Microsoft.MVP.Scripting
--

Quote:
> This is part of the login script that I ahve running:
> If sPath = "*" Or sUNCPath = "*" Then
>   sAdsPath = g_oNet.UserDomain & "/" & g_oNet.UserName
>   Set oAdsObj = GetObject("WinNT://" & sAdsPath & "user")
>   If sPath = "*" Then sPath = oAdsObj.HomeDirDrive
>   If sUNCPath = "*" Then sUNCPath = oAdsObj.HomeDirectory
>   Set oAdsOBJ = Nothing
>  End If
> I have winNT and win98 users logging in the WinNt users work fine but win98
> users are not working. Is there a way to get the users homedir info for win
> 98??

> Marc Hayes



Sun, 13 Apr 2003 03:00:00 GMT  
 Getting Win98 to map drives based upon Group Membership

ok this tells me the domain. But What about group membership????

Quote:

> Q188602 - INFO: UserDomain Method Does Not Work Under Win95 with WSH
> http://support.microsoft.com/support/kb/articles/Q188/6/02.ASP

> The above also applies to Win98...

> --
> Michael Harris
> Microsoft.MVP.Scripting
> --


> > This is part of the login script that I ahve running:
> > If sPath = "*" Or sUNCPath = "*" Then
> >   sAdsPath = g_oNet.UserDomain & "/" & g_oNet.UserName
> >   Set oAdsObj = GetObject("WinNT://" & sAdsPath & "user")
> >   If sPath = "*" Then sPath = oAdsObj.HomeDirDrive
> >   If sUNCPath = "*" Then sUNCPath = oAdsObj.HomeDirectory
> >   Set oAdsOBJ = Nothing
> >  End If
> > I have winNT and win98 users logging in the WinNt users work fine but
win98
> > users are not working. Is there a way to get the users homedir info for
win
> > 98??

> > Marc Hayes



Mon, 14 Apr 2003 23:34:30 GMT  
 Getting Win98 to map drives based upon Group Membership

Are you sure you're even getting the username on Win9x???  If you're executing this with On Error
Resume Next you may not be...

Q233976 - Cannot Retrieve UserName Property in Windows Script Host
http://support.microsoft.com/support/kb/articles/Q233/9/76.ASP

Once you have a User object, you can walk its Groups collection.

--
Michael Harris
Microsoft.MVP.Scripting
--

Quote:

> ok this tells me the domain. But What about group membership????


> > Q188602 - INFO: UserDomain Method Does Not Work Under Win95 with WSH
> > http://support.microsoft.com/support/kb/articles/Q188/6/02.ASP

> > The above also applies to Win98...

> > --
> > Michael Harris
> > Microsoft.MVP.Scripting
> > --


> > > This is part of the login script that I ahve running:
> > > If sPath = "*" Or sUNCPath = "*" Then
> > >   sAdsPath = g_oNet.UserDomain & "/" & g_oNet.UserName
> > >   Set oAdsObj = GetObject("WinNT://" & sAdsPath & "user")
> > >   If sPath = "*" Then sPath = oAdsObj.HomeDirDrive
> > >   If sUNCPath = "*" Then sUNCPath = oAdsObj.HomeDirectory
> > >   Set oAdsOBJ = Nothing
> > >  End If
> > > I have winNT and win98 users logging in the WinNt users work fine but
> win98
> > > users are not working. Is there a way to get the users homedir info for
> win
> > > 98??

> > > Marc Hayes



Tue, 15 Apr 2003 08:59:40 GMT  
 
 [ 4 post ] 

 Relevant Pages 

1. Mapping drives based on group membership using ADSI with VBS

2. Mapping drives based on group membership

3. Mapping drives based on group membership using ADSI with VBS

4. Mapping Drives based on Group Membership for Win9x clients

5. Map Drives and Connect Printers based on OU Membership

6. Drive Mappings based on group membership again

7. Drive mappings based on group membership

8. Drive mapping according to group membership

9. A logon script that maps drives according to the users group memberships

10. A logon script that maps drives according to the users group memberships

11. Mapping Drives based on NT global groups

12. mapping drives based on global groups

 

 
Powered by phpBB® Forum Software