Jump to content
Sign in to follow this  
TerarinKerowyn

WMI class

Recommended Posts

TerarinKerowyn

I need help on finding a programs ID number out of Win32.Process then getting each of the process ID and search in the application for tabbed data.


Contact via MSN: [email=terarink_msn@hotmail.com]terarink_msn@hotmail.com[/email], yahoo: terarink_yah

Share this post


Link to post
Share on other sites
ptrex

@TerarinKerowyn

This might get you started.

Dim Const $wbemFlagReturnImmediately = 0x10
Dim Const $wbemFlagForwardOnly = 0x20

$oWMIService = ObjGet("winmgmts:\\" & @ComputerName & "\root\CIMV2")
If Not @error Then
    $oItems = $oWMIService.ExecQuery("SELECT * FROM Win32_Process", "WQL", $wbemFlagReturnImmediately + $wbemFlagForwardOnly)

    For $Item In $oItems
        ConsoleWrite("Name: " & @tab & @tab& @tab& "ProcessId: " & @tab & "CommandLine: " & @tab & @LF)
        ConsoleWrite($Item.Name & @tab & @tab& $Item.ProcessId & @tab& @tab & $Item.CommandLine & @LF)
    Next
EndIf

Share this post


Link to post
Share on other sites
TerarinKerowyn

I already have the entire list of win32.process but now with this information how to ensure the object is webpage and how to find other webpages in the same image. I am running vista so something is wrong with the Shell.Application when you have two or more windows open at the same time. The cause of this thing is it is reading the same handle over and over again for as many times as it is viewed open. But win32.process gives you the applications handle (two or more different handle numbers)

Was just thinking that is the easiest way of accomplishing my feat any help would be helpful in finding how to fix this


Contact via MSN: [email=terarink_msn@hotmail.com]terarink_msn@hotmail.com[/email], yahoo: terarink_yah

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
Sign in to follow this  

×

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.