Page 1 of 1 1
Topic Options
#156556 - 2006-02-03 07:06 AM What am i doing wrong?
Tibby Offline
Lurker

Registered: 2006-02-03
Posts: 1
Code:
 
; KIXTART.SCR
;
; KiXtart sample default logon script
;
; Note : This code sample is provided for demonstration purposes only.
; Microsoft makes no warranty, either express or implied,
; as to its usability in any given situation.
;
; Copyright (C) 2001 Ruud van Velsen.
; All rights reserved.
;
CLS

small
Color b+/n
BOX (0,0,24,79,GRID) ; 'background grid'
Color b/n
BOX (8,21,18,61,Å) ; 'shadow' of the box
Color g+/n
BOX (7,20,17,60,FULL)

Color w+/n
AT ( 9,25) "Userid : " ; display some text strings
AT (10,25) "Full name : "
AT (11,25) "Privilege : "
AT (12,25) "Workstation : "
AT (13,25) "Domain : "
AT (14,25) "Logon Server : "

Color y+/n
AT ( 9,40) @userid ; ...and some macro's
AT (10,40) @fullname
AT (11,40) @priv
AT (12,40) @wksta
AT (13,40) @domain
AT (14,40) @lserver


If InGroup("\\Remax-Server\Administrators")
? "You are a member of the ADMINISTRATORS group"
USE T: /d
USE U: /d
USE V: /d
USE W: /d
USE X: /d
USE T: "\\REMAX-SERVER\OWNERS"
USE U: "\\REMAX-SERVER\OFFICE MANAGER"
USE V: "\\REMAX-SERVER\AGENTS"
USE W: "\\REMAX-SERVER\RECEPTION"
USE X: "\\REMAX-SERVER\SECRETARIES"
EndIf
If
InGroup("\\Remax-Server\Owners")
? "You are a member of the OWNERS group"
USE T: /d
USE U: /d
USE V: /d
USE W: /d
USE X: /d
USE T: "\\REMAX-SERVER\OWNERS"
USE U: "\\REMAX-SERVER\OFFICE MANAGER"
USE V: "\\REMAX-SERVER\AGENTS"
USE W: "\\REMAX-SERVER\RECEPTION"
USE X: "\\REMAX-SERVER\SECRETARIES"
If @error
? "Ohoh, redirect failed with errorcode : " + @error
EndIf
EndIf
If
InGroup("\\Remax-Server\Managers")
? "You are a member of the MANAGERS group"
USE U: /d
USE V: /d
USE W: /d
USE X: /d
USE U: "\\REMAX-SERVER\OFFICE MANAGER"
USE V: "\\REMAX-SERVER\AGENTS"
USE W: "\\REMAX-SERVER\RECEPTION"
USE X: "\\REMAX-SERVER\SECRETARIES"
If @error
? "Ohoh, redirect failed with errorcode : " + @error
EndIf
EndIf
If
InGroup("\\Remax-Server\Secretaries")
? "You are a member of the SECRETARIES group"
USE V: /d
USE W: /d
USE X: /d
USE V: "\\REMAX-SERVER\AGENTS"
USE W: "\\REMAX-SERVER\RECEPTION"
USE X: "\\REMAX-SERVER\SECRETARIES"
If @error
? "Ohoh, redirect failed with errorcode : " + @error
EndIf
EndIf
If
InGroup("\\Remax-Server\Reception")
? "You are a member of the RECEPTION group"
USE V: /d
USE W: /d
USE V: "\\REMAX-SERVER\AGENTS"
USE W: "\\REMAX-SERVER\RECEPTION"
If @error
? "Ohoh, redirect failed with errorcode : " + @error
EndIf
EndIf
If
InGroup("\\Remax-Server\Agents")
? "You are a member of the AGENTS group"
USE V: /d
USE V: "\\REMAX-SERVER\AGENTS"
If @error
? "Ohoh, redirect failed with errorcode : " + @error
EndIf
EndIf





Color w/n
AT (16,25) "Press anykey to continue."
get $x
exit



When i log in using any user part of the groups other than Administrators, nothing runs. When i log in using Administrator, the script works.

Can anyone tell me what i am doing wrong.

I ran into this same problem with a VBScript that i wrote, and tried KiXtart in hopes that it would solve my problem.

Thank you in advance

Top
#156557 - 2006-02-03 07:58 AM Re: What am i doing wrong?
NTDOC Administrator Offline
Administrator
*****

Registered: 2000-07-28
Posts: 11634
Loc: Space
Well right off the bat with out detailed analysis of your code I can see that anyone that is in more then one group is going to unmap and remap a few times.

You may want to consider the SELECT CASE ENDSELECT method.

What version of KiXtart are you using and what client types do you need to support 9x/nt/2k/xp/2k3 ?
What is the domain model NT/AD?

Top
#156558 - 2006-02-04 12:00 AM Re: What am i doing wrong?
thepip3r Offline
Hey THIS is FUN
*****

Registered: 2005-03-02
Posts: 350
Unless you're trying for an concatenation type method of mapped drives like we run. BUT, just like NTDOC said, because you have different drives mapping under the same drive letters, you'll never get the concatenation, you'll get the very last set of drives for the last If/Endif conditional that evals to true.

Edit: And unless your users somehow are getting access denied while trying to map drives (and they shouldn't), mapping drives shouldn't matter for who with what rights logs into the machine.


Edited by thepip3r (2006-02-04 12:01 AM)

Top
Page 1 of 1 1


Moderator:  Jochen, Allen, Radimus, Glenn Barnas, ShaneEP, Ruud van Velsen, Arend_, Mart 
Hop to:
Shout Box

Who's Online
0 registered and 2375 anonymous users online.
Newest Members
fgarcia, Viginette, ManuvdWielNL, Sir_Barrington, batdk82
17889 Registered Users

Generated in 0.155 seconds in which 0.093 seconds were spent on a total of 12 queries. Zlib compression enabled.

Search the board with:
superb Board Search
or try with google:
Google
Web kixtart.org