Results 1 to 3 of 3

Thread: Active DS help!?!

  1. #1

    Thread Starter
    Hyperactive Member
    Join Date
    Dec 2000
    Location
    Denver
    Posts
    265

    Active DS help!?!

    I'm going through some source code I found that returns the users, groups, and computers in a given domain. Among the project references is a reference to Active DS Type Library. The code that has me stumped is this part:

    Code:
    container.Filter = Array("computer")
    Dim computer As IADsComputer
    For Each computer In container
    Combo4.AddItem computer.Name
    Next
    Almost all of it is self explanatory...but what the heck is this Array("computer") deal? I've gone through every line of code in the project (also by using Find) and I can't find anywhere that an array is dim'd, redim'd etc...so what the heck is this, and what is it used for?

    ~Acoustic

  2. #2

    Thread Starter
    Hyperactive Member
    Join Date
    Dec 2000
    Location
    Denver
    Posts
    265
    oh yea...the container is set as follows:

    Code:
    Dim container As IADsContainer

  3. #3
    Hyperactive Member LeeSalter's Avatar
    Join Date
    Oct 2002
    Location
    Notts, England
    Posts
    307
    This line basically Filters the container to include only Computer objects in the specified Domain, and holds the results in a new dynamic Array. You can also filter for "Users" and "Groups".

    Hope this helps.
    "I'm Brian and so is my Wife"

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width