Page 1 of 1 1
Topic Options
#196685 - 2009-11-13 11:06 AM ingroup() and universal groups
zwu Offline
Fresh Scripter

Registered: 2009-11-12
Posts: 6
Loc: Austria
Hi Guys!

You have probable heard this thing lots of times, but i kindof didn't find anything fitting for my situation. My setup is simple i want to check whether a user is in a group:
ingroup("mydomain\somegroup")

the problem is that somegroup is a universial group which i am also member of. if i run the script ingroup reports a 0 (no member) - if i try it at my collegue it works (result 1) the only difference is that he runs windows7 and i run WinXP.
And Yes i've tried the /f and /f: options. The Group doesnt show in the tokencache as well as in enumgroup() which will give the same results i guess...

anyone got any clues? Code Below:

regards!

 Code:
IF INGROUP("DOMAIN\Navision")
	?"Navision Member"
		IF READPROFILESTRING("\\stor03\StartupInfo\navVersion.ini", "USERS", "@USERID") < 1
			WRITEPROFILESTRING("\\stor03\StartupInfo\navVersion.ini","USERS","@USERID","0")
		ENDIF
		IF EXIST ("%APPDATA%\fin.zup")
			IF NOT EXIST ("\\stor02\navforms\zup\prod\%username%.zup") 
				copy "%APPDATA%\fin.zup" "\\stor02\navforms\zup\prod\%username%.zup"	
			ENDIF
			IF NOT EXIST ("\\stor02\navforms\zup\test\%username%.zup")
				copy "%APPDATA%\fin.zup" "\\stor02\navforms\zup\Test\%username%.zup"	
			ENDIF
			IF NOT EXIST ("\\stor02\navforms\zup\FR\prod\%username%.zup")
				copy "%APPDATA%\fin.zup" "\\stor02\navforms\zup\FR\prod\%username%.zup"	
			ENDIF
			IF NOT EXIST ("\\stor02\navforms\zup\FR\test\%username%.zup")
				copy "%APPDATA%\fin.zup" "\\stor02\navforms\zup\FR\test\%username%.zup"	
			ENDIF
		ENDIF
ENDIF


Edited by zwu (2009-11-13 11:12 AM)
Edit Reason: forgot code

Top
#196688 - 2009-11-13 02:15 PM Re: ingroup() and universal groups [Re: zwu]
Allen Administrator Offline
KiX Supporter
*****

Registered: 2003-04-19
Posts: 4572
Loc: USA
Is this your issue?
http://www.kixtart.org/forums/ubbthreads.php?ubb=showflat&Number=196497#Post196497
_________________________
(... better days ahead)

Top
#196689 - 2009-11-13 03:05 PM Re: ingroup() and universal groups [Re: Allen]
zwu Offline
Fresh Scripter

Registered: 2009-11-12
Posts: 6
Loc: Austria
No not really - in my Case it works with Win7 and not with WinXP
I run a Win2k3 Domain, just if anyone wants to know - i will try the reentry into the domain thou...

Top
#196691 - 2009-11-13 03:49 PM Re: ingroup() and universal groups [Re: zwu]
Allen Administrator Offline
KiX Supporter
*****

Registered: 2003-04-19
Posts: 4572
Loc: USA
Did you find any Eventlog messages?
_________________________
(... better days ahead)

Top
#196738 - 2009-11-18 08:36 AM Re: ingroup() and universal groups [Re: Allen]
zwu Offline
Fresh Scripter

Registered: 2009-11-12
Posts: 6
Loc: Austria
there were 4 eventlog messages but none fitting for the problem - they came when i was trying alternatives in syntax and that was just plain wrong.
what i found thou - that this must be an error in the domain somehow, because when i analyze the output of "gpresult" i can see that i am not in the group i should be in, when i check in the administrative tool i am a member... strange - anyone got ideas how this can happen?

Top
#196739 - 2009-11-18 08:41 AM Re: ingroup() and universal groups [Re: zwu]
Arend_ Moderator Offline
MM club member
*****

Registered: 2005-01-17
Posts: 1896
Loc: Hilversum, The Netherlands
Could you try it without specifying the domain?
 Code:
IF INGROUP("Navision")
  ? "Navision Member"
ENDIF

Top
#196829 - 2009-11-25 02:30 PM Re: ingroup() and universal groups [Re: Arend_]
zwu Offline
Fresh Scripter

Registered: 2009-11-12
Posts: 6
Loc: Austria
Problem is fixed - Reason was... i really don't know - some kind of troubles with the computer domain account - only on this PC gpresult did not see my membership in the navision group, on every othe pc it works.
Well now it does too on my PC but why i dunno. Thanks again everybody!

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 2220 anonymous users online.
Newest Members
Viginette, ManuvdWielNL, Sir_Barrington, batdk82, StuTheCoder
17888 Registered Users

Generated in 0.07 seconds in which 0.039 seconds were spent on a total of 13 queries. Zlib compression enabled.

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