Wrox Programmer Forums
Go Back   Wrox Programmer Forums > C# and C > C# 1.0 > C#
|
C# Programming questions specific to the Microsoft C# language. See also the forum Beginning Visual C# to discuss that specific Wrox book and code.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the C# section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
 
Old April 29th, 2008, 12:17 AM
Registered User
 
Join Date: Apr 2008
Posts: 1
Thanks: 0
Thanked 0 Times in 0 Posts
Default Receiveing Computer properties from active directo

Dear Freinds,

I am trying to receive a computer properties by using the active directory.
The properties may be: Computer Name, DNS name, Description etc ..

The follwoing code is used:


DirectorySearcher mySearcher = new DirectorySearcher(entry);
SearchResult result = mySearcher.FindOne();

foreach(SearchResult result in ySearcher.FindAll())
{
strName = result.GetDirectoryEntry().Name;
string allNames = this.GetProperties(result.GetDirectoryEntry());
}

However only the name of the computer is accessed.
Apprecaite your assistance how can I receive the DNS, Description Etc. ...

THanks,
moti







Similar Threads
Thread Thread Starter Forum Replies Last Post
how to get client computer name ramuis78 ASP.NET 1.0 and 1.1 Basics 1 March 11th, 2007 10:21 AM
Computer login name deontae45 ASP.NET 1.x and 2.0 Application Design 2 September 7th, 2006 08:18 AM
Monitoring users login/logout to my active directo Gu General .NET 0 June 10th, 2005 11:49 AM
how do i get computer name shankhan Javascript How-To 0 May 28th, 2005 03:43 PM





Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.