#20384 - 2002-04-22 11:40 PM
Problem mapping clients InGroup
|
Seth Able
Lurker
Registered: 2002-04-14
Posts: 4
|
Hi all!
I have a problem... I've got a mixed environment with win98 and win2k clients off a single WinNT4 PDC. I've installed/started the KXRPC service but for some reason I still can't get mappings to occur based on group memberships.
Any ideas? Here is my script for you review (please don't laugh to hard, I'm not a good programmer!)
Seth
--== Login.kix Script ==-- ; Login Script for [customer] ; Written by [me] ; April 2002 ; ; This script contains portions of public domain scripts (Thanks!)
; Banners ; This informs the user about the use of workstations ; CLS small Color b+/n BOX (0,0,24,79,GRID) ; 'background grid' Color b/n BOX (3,7,6,76,) ; 'shadow' of the box Color g+/n BOX (2,6,5,75,FULL) Color b/n BOX (8,23,18,61,) ; 'shadow' of the box Color g+/n BOX (7,22,17,60,FULL)
color w+/n AT (3, 13) "This machine is for [company] business use ONLY!" AT (4, 10) "Do not Load, Install or Open files unless specifically needed!"
Color c+/n AT ( 9,25) "You're Login Credentials are: " Color w+/n AT (11,25) "Userid : " ; display some text strings AT (12,25) "Full name : " AT (13,25) "Privilege : " AT (14,25) "Workstation : " AT (15,25) "Domain : " AT (16,25) "Logon Server : "
Color y+/n AT (11,40) @userid ; ...and some macro's AT (12,40) @fullname AT (13,40) @priv AT (14,40) @wksta AT (15,40) @domain AT (16,40) @lserver SLEEP 6 CLS
; Mappings ; This maps server shares based on user credentials
Color b+/n AT (1, 5) "*************************************************************" AT (2, 5) "** **" AT (3, 5) "*************************************************************" color w+/n AT (2, 8) "Never save an important file to the local drive!! (C:\)" Color w/n AT (4, 5) "Only files saved to the network are backed up! (K: or higher)" Color c+/n AT (24, 5) AT (6, 10) "You're drive mappings are being established..."
color w/n AT (8, 10) "Clearing old maps ... " USE "*" /DELETE color w+/n AT (8, 32) "Done!" color w/n AT (9, 10) "Private share:" USE K: @HOMESHR color w+/n AT (9, 40) "K:\" color w/n AT (10, 10) "Public share:" USE L: \\PDC\PUBLIC color w+/n AT (10, 40) "L:\"
; Mapping Department Shares $HL = 10 IF InGroup("Accounting") let $HL = $HL + 1 color w/n AT ($HL, 10) "Accounting Department share:" USE M: "\\PDC\ACCOUNTING" color w+/n AT ($HL, 40) "M:\" ENDIF IF InGroup("Administrators") let $HL = $HL + 1 color w/n AT ($HL, 10) "Administrators share:" USE N: "\\PDC\ADMINS" color w+/n AT ($HL, 40) "N:\" ENDIF IF InGroup("Management") let $HL = $HL + 1 color w/n AT ($HL, 10) "Management share:" USE O: "\\PDC\MANAGEMENT" color w+/n AT ($HL, 40) "O:\" ENDIF IF InGroup("Parts") let $HL = $HL + 1 color w/n AT ($HL, 10) "Parts Department share:" USE P: "\\PDC\PARTS" color w+/n AT ($HL, 40) "P:\" ENDIF IF InGroup("Payroll") let $HL = $HL + 1 color w/n AT ($HL, 10) "Payroll Department share:" USE Q: "\\PDC\PAYROLL" color w+/n AT ($HL, 40) "Q:\" ENDIF IF InGroup("Sales") let $HL = $HL + 1 color w/n AT ($HL, 10) "Sales Department share:" USE R: "\\PDC\SALES" color w+/n AT ($HL, 40) "R:\" ENDIF IF InGroup("Services") let $HL = $HL + 1 color w/n AT ($HL, 10) "Service Department share:" USE S: "\\PDC\SERVICE" color w+/n AT ($HL, 40) "S:\" ENDIF SLEEP 10 CLS
; Misc ; Various little things I want to do ; Not used yet ; ; Set a common time. See MS Q131715 for info. ;AT (2, 10) "Synch'ing Time with the server ... ; SETTIME \\PDC ;AT (2, 45) "Done!" SLEEP 10
exit
_________________________
-=-=-=-=-=-=-=-=-=-=-=-=-=-
Constructive Self-Delusion
-=-=-=-=-=-=-=-=-=-=-=-=-=-
|
|
Top
|
|
|
|
#20385 - 2002-04-22 11:43 PM
Re: Problem mapping clients InGroup
|
Seth Able
Lurker
Registered: 2002-04-14
Posts: 4
|
Forgot to mention;
K: and L: map just fine, then the script seems to abort (doesn't reach the next "SLEEP 10" command). the "$HL" is my attempt to have the display of mapped drives stay nice and clean. Did I do that wrong perhaps?
One last thing, how can I make the DOS window display on win2k clients? Currently the box stays minimized when it runs.
Thanks again!
_________________________
-=-=-=-=-=-=-=-=-=-=-=-=-=-
Constructive Self-Delusion
-=-=-=-=-=-=-=-=-=-=-=-=-=-
|
|
Top
|
|
|
|
#20388 - 2002-04-23 05:44 AM
Re: Problem mapping clients InGroup
|
MCA
KiX Supporter
   
Registered: 2000-04-28
Posts: 5152
Loc: Netherlands, EU
|
Dear,
A welcome to this board.
First some comment.
- "let $hl = $hl + 1" is the right way of assigning. correct will be "$hl = $hl + 1".
LET is an undefined element which will abort your script. - specify InGroup("Accounting") <> 0 instead of InGroup("Accounting").
our version will work for kixtart releases. - specifies 'line style' in your BOX function call as string.
BOX (0,0,24,79,"GRID") ; 'background grid' BOX (3,7,6,76,"") ; 'shadow' of the box BOX (2,6,5,75,"FULL") BOX (8,23,18,61,"") ; 'shadow' of the box BOX (7,22,17,60,FULL) - keep your SLEEP time low. everybody can read information with 3-5 seconds.
- we replace USE L: \\PDC\PUBLIC with USE L: "\\PDC\PUBLIC"
Our version:
code:
; Login Script for [customer] ; Written by [me] ; April 2002 ; ; This script contains portions of public domain scripts (Thanks!)
; Banners ; This informs the user about the use of workstations ; CLS SMALL COLOR b+/n BOX (0,0,24,79,"GRID") ; 'background grid' COLOR b/n BOX (3,7,6,76,"") ; 'shadow' of the box COLOR g+/n BOX (2,6,5,75,"FULL") COLOR b/n BOX (8,23,18,61,"") ; 'shadow' of the box COLOR g+/n BOX (7,22,17,60,"FULL")
COLOR w+/n AT (3, 13) "This machine is for [company] business use ONLY!" AT (4, 10) "Do not Load, Install or Open files unless specifically needed!"
COLOR c+/n AT ( 9,25) "You're Login Credentials are: " COLOR w+/n AT (11,25) "Userid : " ; display some text strings AT (12,25) "Full name : " AT (13,25) "Privilege : " AT (14,25) "Workstation : " AT (15,25) "Domain : " AT (16,25) "Logon Server : "
COLOR y+/n AT (11,40) @userid ; ...and some macro's AT (12,40) @fullname AT (13,40) @priv AT (14,40) @wksta AT (15,40) @domain AT (16,40) @lserver SLEEP 5
; Mappings ; This maps server shares based on user credentials
CLS COLOR b+/n AT (1, 5) "*************************************************************" AT (2, 5) "** **" AT (3, 5) "*************************************************************" COLOR w+/n AT (2, 8) "Never save an important file to the local drive!! (C:\)" COLOR w/n AT (4, 5) "Only files saved to the network are backed up! (K: or higher)" COLOR c+/n AT (24, 5) AT (6, 10) "You're drive mappings are being established..."
COLOR w/n AT (8, 10) "Clearing old maps ... " USE "*" /delete COLOR w+/n AT (8, 32) "Done!" COLOR w/n AT (9, 10) "Private share:" USE K: @homeshr COLOR w+/n AT (9, 40) "K:\" COLOR w/n AT (10, 10) "Public share:" USE L: "\\PDC\PUBLIC" COLOR w+/n AT (10, 40) "L:\"
; Mapping Department Shares $hl = 10 IF InGroup("Accounting") <> 0 $hl = $hl + 1 COLOR w/n AT ($hl, 10) "Accounting Department share:" USE M: "\\PDC\ACCOUNTING" COLOR w+/n AT ($hl, 40) "M:\" ENDIF IF InGroup("Administrators") <> 0 $hl = $hl + 1 COLOR w/n AT ($hl, 10) "Administrators share:" USE N: "\\PDC\ADMINS" COLOR w+/n AT ($hl, 40) "N:\" ENDIF IF InGroup("Management") <> 0 $hl = $hl + 1 COLOR w/n AT ($hl, 10) "Management share:" USE O: "\\PDC\MANAGEMENT" COLOR w+/n AT ($hl, 40) "O:\" ENDIF IF InGroup("Parts") <> 0 $hl = $hl + 1 COLOR w/n AT ($hl, 10) "Parts Department share:" USE P: "\\PDC\PARTS" COLOR w+/n AT ($hl, 40) "P:\" ENDIF IF InGroup("Payroll") <> 0 $hl = $hl + 1 COLOR w/n AT ($hl, 10) "Payroll Department share:" USE Q: "\\PDC\PAYROLL" COLOR w+/n AT ($hl, 40) "Q:\" ENDIF IF InGroup("Sales") <> 0 $hl = $hl + 1 COLOR w/n AT ($hl, 10) "Sales Department share:" USE R: "\\PDC\SALES" COLOR w+/n AT ($hl, 40) "R:\" ENDIF IF InGroup("Services") <> 0 $hl = $hl + 1 COLOR w/n AT ($hl, 10) "Service Department share:" USE S: "\\PDC\SERVICE" COLOR w+/n AT ($hl, 40) "S:\" ENDIF SLEEP 5 CLS
; Misc ; Various little things I want to do ; Not used yet ; ; Set a common time. See MS Q131715 for info. ;AT (2, 10) "Synch'ing Time with the server ... ; SETTIME \\PDC ;AT (2, 45) "Done!" SLEEP 5
EXIT
The problem with undefined keywords we are verifying with our tool kixref which you can find on our site. The output of our call kixref input.kix output /warnings was
code:
Warnings about unknown keywords
b ? 12 14 18 50 c ? 27 58 full ? 17 21 g ? 16 20 grid ? 13 k: ? 69 l: ? 74 let ? 81 89 97 105 113 121 129 m: ? 84 n ? 12 14 16 18 20 23 27 29 37 50 54 56 58 62 65 67 70 72 75 82 85 90 93 98 101 106 109 114 117 122 125 130 133 n: ? 92 o: ? 100 p: ? 108 pdc\public ? 74 q: ? 116 r: ? 124 s: ? 132 w ? 23 29 54 56 62 65 67 70 72 75 82 85 90 93 98 101 106 109 114 117 122 125 130 133 y ? 37
Summary - kixtart 4.10/3.04e
boldsymbols 0 commands 9 functions 3 labels 0 macros 7 variables 1
env 0 udf 0 ? 19
gosub 0 goto 0
39
Block Structure
do:until [0:0] for|each:in|to:step|next [0|0:0|0:0|0] function:endfunction [0:0] if:else:endif [7:0:7] select:case:endselect [0:0:0] while:loop [0:0]
7 blocks
most warnings has to deal the color settings, but LET, FULL, GRID and PDC\PUBLIC should be modified or removed. greetings.
btw: symbol on our homepage has been linked to related http://kixtart.org topic.
|
|
Top
|
|
|
|
Moderator: Jochen, Allen, Radimus, Glenn Barnas, ShaneEP, Ruud van Velsen, Arend_, Mart
|
0 registered
and 764 anonymous users online.
|
|
|