You are using the wrong object to get the various properties of - given the names you've used, you should be using oComputer1. Neil > -----Original Message----- > From: Chris Lynch [mailto:lynch00@xxxxxxx] > Sent: 18 November 2002 18:44 > To: thin@xxxxxxxxxxxxx > Subject: [THIN] Re: OT: VBScript/WSH/WMI question. > Ok. So I took your suggestion, and I have updated the code to this: > > Option explicit =20 > Dim oContainer, oComputer1, oNetwork > Dim sDomainName, sComputer > Set oNetwork =3D WScript.CreateObject("WScript.Network") > =20 > Set oContainer =3D GetObject("WinNT://AXCENT") > oContainer.Filter =3D Array("user" & "$") > For Each oComputer1 in oContainer =09 > If oContainer.UserFlags And UF_SERVER_TRUST_ACCOUNT Then=20 > Wscript.Echo oComputer1.Name & " is a Server." > Elseif oContainer.UserFlags And UF_DONT_EXPIRE_PASSWD Then > Wscript.Echo oComputer1.Name & " is a Domain > Controller." > Elseif oContainer.UserFlags And > UF_WORKSTATION_TRUST_ACCOUNT Then > Wscript.Echo oComputer1.Name & " is a Workstation." > End If > Next > > MsgBox "DONE." > > I get the following error message: > > C:\Working>cscript getserverlist2.vbs >servelist2.txt > C:\Working\getserverlist2.vbs(9, 4) Microsoft VBScript > runtime error: = Object doe sn't support this property or > method: 'UserFlags' > > Anyone know what I'm doing wrong? *********************************************************************** This e-mail and its attachments are intended for the above named recipient(s) only and are confidential and may be privileged. If they have come to you in error you must take no action based on them, nor must you copy or disclose them or any part of their contents to any person or organisation; please notify the sender immediately and delete this e-mail and its attachments from your computer system. Please note that Internet communications are not necessarily secure and may be changed, intercepted or corrupted. We advise that you understand and observe this lack of security when e-mailing us and we will not accept any liability for any such changes, interceptions or corruptions. Although we have taken steps to ensure that this e-mail and its attachments are free from any virus, we advise that in keeping with good computing practice the recipient should ensure they are actually virus free. Copyright in this e-mail and attachments created by us belongs to Littlewoods. Littlewoods takes steps to prohibit the transmission of offensive, obscene or discriminatory material. If this message contains inappropriate material please forward the e-mail intact to postmaster@xxxxxxxxxxxxxxxxx and it will be investigated. Statements and opinions contained in this e-mail may not necessarily represent those of Littlewoods. Please note that e-mail communication may be monitored. Registered office: Littlewoods Retail Limited, Sir John Moores Building, 100 Old Hall Street, Liverpool, L70 1AB Registered no: 421258 http://www.littlewoods.com *********************************************************************** *********************************************** This Weeks Sponsor: Wyse Technologies Get a free whitepaper on how to secure your corporate data from Wyse. Click Below. http://thethin.net/wyse.cfm *********************************************** For Archives, to Unsubscribe, Subscribe or set Digest or Vacation mode use the below link. http://thethin.net/citrixlist.cfm