lib/win32/activate.rb
# Find parent process id ( by WMI )
Find parent process id ( by WMI )
Find parent process id ( by WMI )
def find_parent_pid pid
      ppid = nil
      wmi.ExecQuery("SELECT * FROM Win32_Process WHERE ProcessID=#{pid}").each{|i|
        ppid = i.ParentProcessID
      }
      return ppid
    end
def find_parent_pid pid ppid = nil wmi . ExecQuery ( "SELECT * FROM Win32_Process WHERE ProcessID=#{pid}" ) . each { | i | ppid = i . ParentProcessID } return ppid end
Find parent process id ( by WMI )
Find parent process id ( by WMI )
pid
<not_specific>