Search found 14825 matches

by jvierra
Wed May 07, 2008 3:32 am
Forum: VBScript
Topic: Large Group Problem
Replies: 10
Views: 7423

Large Group Problem

I am starting to round up all of my notes on this: THe foolowing is from : http://msdn.microsoft.com/en-us/library/ms676302.aspx The version of the server that supplies the requested data determines the maximum number of values that can be retrieved in a single query. The following table lists the s...
by jvierra
Tue May 06, 2008 1:26 pm
Forum: VBScript
Topic: Large Group Problem
Replies: 10
Views: 7423

Large Group Problem

Here is one example: Const increment = 1000 Function GetGroupMembers(aDSPath)     Dim adsi     Dim group, members, member     Dim lowRange, highRange         lowRange = 0     highRange = increment - 1         Set adsi = GetObject(aDSPath)         While Not bDone             strRange = "member;range=...
by jvierra
Tue May 06, 2008 6:45 am
Forum: VBScript
Topic: Large Group Problem
Replies: 10
Views: 7423

Large Group Problem

Yes - there is a limit of 1000 items per query by default on AD. You need to select them in ranges. I will look into the online docs for the discussion of how to get around this limit. I don't have a working example at hand. YOu could also look in MSDN lib for "AD query limit" - I thnk that will ret...
by jvierra
Fri May 02, 2008 5:01 am
Forum: VBScript
Topic: Logon Script does not create instance of HTA
Replies: 17
Views: 12613

Logon Script does not create instance of HTA

User interaction during logon from USERINIT may be a problem. YOu have no control over when the script is executed. It may be executed before all components are completely initilized. Try setting GP to run script "sync". The run "async" by default. Sometimes this can help. Look in GP logs and/or tur...
by jvierra
Thu May 01, 2008 8:30 am
Forum: VBScript
Topic: DNS Search
Replies: 2
Views: 1198

DNS Search

Using "WHERE DnsServerName = 'myhostname'" as a query filter will work to isolate one or more host names. You need to do the IP outside of the query because a string match won't behave as expected in the WHERE clause. YOu can use a single IP in teh WHERE clause and you can use WHERE ip > '192' AND I...
by jvierra
Thu May 01, 2008 3:39 am
Forum: VBScript
Topic: DNS Search
Replies: 2
Views: 1198

DNS Search

Sorry - I don't see how it can be done with a filter. This may be what you are looking for: strComputer = "." Set objWMIService = GetObject("winmgmts:" & strComputer & "rootMicrosoftDNS") Set colItems = objWMIService.ExecQuery("Select * from MicrosoftDNS_AType") For Each objItem in colItems     matc...
by jvierra
Thu May 01, 2008 2:52 am
Forum: VBScript
Topic: Scripts to complete Soxs audit
Replies: 1
Views: 882

Scripts to complete Soxs audit

This is an old and very common request. The Windows system has built in support for listing this information at teh command prompt. For the local system use teh following command: net localgroup administrators For the domain ytou would need to enumerate all groups that can infer admin privileges: ne...
by jvierra
Tue Apr 29, 2008 5:52 am
Forum: VBScript
Topic: Calculate time to complete script.
Replies: 2
Views: 1709

Calculate time to complete script.

The Windows Resource Kit Tools has an excellent utility for doing various command timings if you need more than the above. Timeit.exe TimeIt is a command-line tool that records the time a specified command takes to run. File Required Timeit.exe TimeIt Syntax timeit [-f FileName] [-a] [-c] [-i] [-d] ...
by jvierra
Mon Apr 28, 2008 3:56 am
Forum: PowerShell
Topic: computer asset inventory
Replies: 59
Views: 44212

computer asset inventory

A little better explanation of how WMI works with files: PS> Get-WmiObject -Query "SELECT * FROM cim_datafile where filename='boot'" Compressed : False Encrypted : False Size : Hidden : True Name : <FONT color=#cc0000>c:boot.ini</FONT> Readable : True System File : Version : Writeable : False Compre...
by jvierra
Mon Apr 28, 2008 3:35 am
Forum: PowerShell
Topic: computer asset inventory
Replies: 59
Views: 44212

computer asset inventory

I am going to stress this very heavily Dee. You really need to get a book or take a class in PowerShell. YOu are asing questions about each lin eof code. Many of these questions you are very close to having an answer for but it appears you lack some of the fundamentals. Save yourseld some frustratio...