Windows Vista Forums
Vista Forums Home Join Vista Forums Windows 7 Forum Vista Tutorials Tags
Welcome to Windows Vista Forums. Our forum is dedicated to helping you find solutions with any problems, errors or issues you are experiencing with Windows Vista. The Vista forum also covers news and updates and has an extensive Windows Vista tutorial section that covers a wide range of tips and tricks.

Go Back   Vista Forums > Misc Newsgroups > VB Script

Vista - ADSystemInfo and ComputerName

Reply
 
Old 09-21-2009   #1 (permalink)
Bryan


 
 

ADSystemInfo and ComputerName

Set objSysInfo = CreateObject("ADSystemInfo")
sTmp = objSysInfo.ComputerName
If err <> 0 Then
wsh.echo err.description
End If

This script echos a "Permission Denied" on some machines. I have been unable
to determine the cause or a fix. I have re-registered the activeds.dll. Not
sure what
else to try. Anyone have any ideas?

My System SpecsSystem Spec
Old 09-21-2009   #2 (permalink)
Richard Mueller [MVP]


 
 

Re: ADSystemInfo and ComputerName

Bryan wrote:
Quote:

> Set objSysInfo = CreateObject("ADSystemInfo")
> sTmp = objSysInfo.ComputerName
> If err <> 0 Then
> wsh.echo err.description
> End If
>
> This script echos a "Permission Denied" on some machines. I have been
> unable
> to determine the cause or a fix. I have re-registered the activeds.dll.
> Not
> sure what
> else to try. Anyone have any ideas?
I think the only time I've seen that code fail is when the user is not
authenticated to the domain (or the client is older than Windows 2000).
Could the user be logged into the local computer?

--
Richard Mueller
MVP Directory Services
Hilltop Lab - http://www.rlmueller.net
--


My System SpecsSystem Spec
Old 09-22-2009   #3 (permalink)
Bryan


 
 

Re: ADSystemInfo and ComputerName



"Richard Mueller [MVP]" wrote:
Quote:

> Bryan wrote:
>
Quote:

> > Set objSysInfo = CreateObject("ADSystemInfo")
> > sTmp = objSysInfo.ComputerName
> > If err <> 0 Then
> > wsh.echo err.description
> > End If
> >
> > This script echos a "Permission Denied" on some machines. I have been
> > unable
> > to determine the cause or a fix. I have re-registered the activeds.dll.
> > Not
> > sure what
> > else to try. Anyone have any ideas?
>
> I think the only time I've seen that code fail is when the user is not
> authenticated to the domain (or the client is older than Windows 2000).
> Could the user be logged into the local computer?
>
> --
> Richard Mueller
> MVP Directory Services
> Hilltop Lab - http://www.rlmueller.net
> --
>
>
>
Not possible, all clients are XP SP2 and this code is called from user logon
scripts. We have had a significant failure rate with the ADSystemInfo object,
in the neighborbood of 10%.

I have tried to identify files that are needed for ADSystemInfo object to
work but haven't found anything outside of the ActiveDs.dll, in an attempt to
re-install or repair mis-matched files or registry.

Could it be rights? What rights would I need to examine? (File System, AD,
etc)

Thanks in advance for help you can provide.

Bryan
My System SpecsSystem Spec
Old 09-22-2009   #4 (permalink)
Richard Mueller [MVP]


 
 

Re: ADSystemInfo and ComputerName


"Bryan" <Bryan@newsgroup> wrote in message
news:0E6E64AA-2E84-4186-BBB6-F9F5E0D1F730@newsgroup
Quote:

>
>
> "Richard Mueller [MVP]" wrote:
>
Quote:

>> Bryan wrote:
>>
Quote:

>> > Set objSysInfo = CreateObject("ADSystemInfo")
>> > sTmp = objSysInfo.ComputerName
>> > If err <> 0 Then
>> > wsh.echo err.description
>> > End If
>> >
>> > This script echos a "Permission Denied" on some machines. I have been
>> > unable
>> > to determine the cause or a fix. I have re-registered the activeds.dll.
>> > Not
>> > sure what
>> > else to try. Anyone have any ideas?
>>
>> I think the only time I've seen that code fail is when the user is not
>> authenticated to the domain (or the client is older than Windows 2000).
>> Could the user be logged into the local computer?
>>
>> --
>> Richard Mueller
>> MVP Directory Services
>> Hilltop Lab - http://www.rlmueller.net
>> --
>>
>>
>>
>
> Not possible, all clients are XP SP2 and this code is called from user
> logon
> scripts. We have had a significant failure rate with the ADSystemInfo
> object,
> in the neighborbood of 10%.
>
> I have tried to identify files that are needed for ADSystemInfo object to
> work but haven't found anything outside of the ActiveDs.dll, in an attempt
> to
> re-install or repair mis-matched files or registry.
>
> Could it be rights? What rights would I need to examine? (File System, AD,
> etc)
>
> Thanks in advance for help you can provide.
>
> Bryan
When I use the ADSystemInfo object in a VB 6 program, I must include a
reference to activeds.tlb, the Active DS Type Library.

--
Richard Mueller
MVP Directory Services
Hilltop Lab - http://www.rlmueller.net
--


My System SpecsSystem Spec
Reply

Thread Tools


Similar Threads
Thread Forum
Computername .NET General
wds + computername Vista installation & setup
\\computername doesn't work (while \\ip do) Vista networking & sharing
computername Vista account administration


Vista Forums is an independent web site and has not been authorized,
sponsored, or otherwise approved by Microsoft Corporation.
"Windows Vista", the Start Orb, and related materials are trademarks of Microsoft Corp.
© Designer Media Ltd

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46