VSNDK.DebugEngine.AD7ProgramNodeAttach.GetHostPid C# (CSharp) Method

GetHostPid() public method

Gets the system process identifier for the process hosting a program. (http://msdn.microsoft.com/en-us/library/bb162159.aspx)
public GetHostPid ( AD_PROCESS_ID pHostProcessId ) : int
pHostProcessId AD_PROCESS_ID Returns the system process identifier for the hosting process.
return int
        public int GetHostPid(AD_PROCESS_ID[] pHostProcessId)
        {
            // According to the MSDN documentation (http://msdn.microsoft.com/en-us/library/bb162159.aspx),
            // it should return the process id of the hosting process, but what is expected is the program ID...
            pHostProcessId[0].ProcessIdType = (uint)enum_AD_PROCESS_ID.AD_PROCESS_ID_GUID;
            pHostProcessId[0].guidProcessId = m_processGuid;

            return VSConstants.S_OK;
        }