Home All Groups Group Topic Archive Search About
Author
22 Sep 2006 3:07 PM
Vikas Manghani
Hi
I have an OU named TempOU set at my domain controller.
All my users are getting created in this OU.
I have a group policy setup for this OU.
Can anyone tell me how to read the values for these settings in C# code.
i need to read lockoutDuration and maxPwdAge.

Thanks and regards
Vikas Manghani

Author
22 Sep 2006 4:50 PM
Jens Weibler
"Vikas Manghani" <VikasMangh***@discussions.microsoft.com> wrote...
> Hi
> I have an OU named TempOU set at my domain controller.
> All my users are getting created in this OU.
> I have a group policy setup for this OU.
> Can anyone tell me how to read the values for these settings in C# code.
> i need to read lockoutDuration and maxPwdAge.

the two links should help you:
http://www.codeproject.com/dotnet/QueryADwithDotNet.asp
http://www.codeproject.com/dotnet/activedirquery.asp

--
mfg
Jens
Author
23 Sep 2006 9:45 AM
Vikas Manghani
Hi Jens
Thanks for the links.
However I was unable to find how to retrieve the
group policy for the OU.
I need the values for the maxPwdAge and lockoutDuration attributes
that I have set for my OU.
I am able to retrieve the values that are set for the domain as a whole,
But not what I have set for my OU and which override the remaining
domain policies.

Vikas

Show quote
"Jens Weibler" wrote:

> "Vikas Manghani" <VikasMangh***@discussions.microsoft.com> wrote...
> > Hi
> > I have an OU named TempOU set at my domain controller.
> > All my users are getting created in this OU.
> > I have a group policy setup for this OU.
> > Can anyone tell me how to read the values for these settings in C# code.
> > i need to read lockoutDuration and maxPwdAge.
>
> the two links should help you:
> http://www.codeproject.com/dotnet/QueryADwithDotNet.asp
> http://www.codeproject.com/dotnet/activedirquery.asp
>
> --
> mfg
> Jens
>
>
>

AddThis Social Bookmark Button