DaniWeb IT Discussion Community

DaniWeb IT Discussion Community (http://www.daniweb.com/forums/index.php)
-   ColdFusion (http://www.daniweb.com/forums/forum19.html)
-   -   ColdFusion and WMI Query (http://www.daniweb.com/forums/thread126766.html)

lberezinski May 29th, 2008 3:27 pm
ColdFusion and WMI Query
 
Hi all

I’m new to ColdFusion and I have hard time to understand how to run a specific WMI query

Until now I can only dump a WMI Class to a ColdFusion Array
For example

<cfset obj_wmi = CreateObject( "component" , "wmi" ).init() />
<cfset arr_Array = obj_wmi.execQuery ( " Win32_UserAccount " ) />

But what I need to do is similar to the non working code below

<cfset obj_wmi = CreateObject( "component" , "wmi" ).init() />
<cfset arr_Array = obj_wmi.execQuery ( " SELECT SID FROM Win32_UserAccount WHERE Name='UserName' AND Domain='DomainName' " ) />


Thanks in Advance


All times are GMT -4. The time now is 8:27 am.

Forum system based on vBulletin Copyright ©2000 - 2009, Jelsoft Enterprises Ltd.
©2003 - 2009 DaniWeb® LLC