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 - credentials question: seek syntax for domain administratorOpenDSObject arguments

Reply
 
Old 03-20-2009   #1 (permalink)
gimme_this_gimme_that


 
 

credentials question: seek syntax for domain administratorOpenDSObject arguments

I have this clip of code that checks if you are a local Administator
on a computer:

' Bind to local Administrators group on computer.
Set objNS = GetObject("WinNT:")
Set objLocalGroup = objNS.OpenDSObject("WinNT://" & strComputer _
& "/Administrators,group", strUser, strPassword, _
ADS_SECURE_AUTHENTICATION Or ADS_USE_ENCRYPTION)

What is the syntax to OpenDSObject to connect to the global domain
controller?

I'm writing a script that adds users to AD groups that are used in
system wide application that uses NTLM authentication.

I have an account that has permission to manage the groups - but users
can't use that account to log into a computer.

Thanks.

My System SpecsSystem Spec
Old 03-21-2009   #2 (permalink)
gimme_this_gimme_that


 
 

Re: credentials question: seek syntax for domain administratorOpenDSObject arguments

I think the answer to this is:

Set oUser = dso.OpenDSObject(strUserDN, strUsername, strPassword, 1)
My System SpecsSystem Spec
Reply

Thread Tools


Similar Threads
Thread Forum
"Your credentials did not work" remote desktop from Vista on Domain to vista non-domain offsite?? Vista General
Domain Account Credentials to a Workgroup Process (Vista Business) Vista account administration
Is there a way as an administrator in a domain to allow a standard user not to need credentials for only a few applications? Vista account administration
Vista Looking for credentials while joing W2K3 domain controller Vista General
Wrong credentials used on local LAN/Domain when VPN in effect Vista networking & sharing


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