Process2 インターフェイス

更新 : 2007 年 11 月

Process2 オブジェクトは、プロセスのチェックおよび操作に使用されます。Process2 オブジェクトは、Process オブジェクトよりも優先されます。

名前空間 :  EnvDTE80
アセンブリ :  EnvDTE80 (EnvDTE80.dll 内)

構文

'宣言
<GuidAttribute("95AC1923-6EAA-427C-B43E-6274A8CA6C95")> _
Public Interface Process2 _
    Implements Process
'使用
Dim instance As Process2
[GuidAttribute("95AC1923-6EAA-427C-B43E-6274A8CA6C95")]
public interface Process2 : Process
[GuidAttribute(L"95AC1923-6EAA-427C-B43E-6274A8CA6C95")]
public interface class Process2 : Process
public interface Process2 extends Process

' Macro code.
Imports EnvDTE
Imports EnvDTE80
Imports System.Diagnostics
Imports Microsoft.VisualBasic.ControlChars

Public Module Module1

    Sub NativeAttachToLocalCalc()
        Dim dbg2 As EnvDTE80.Debugger2
        dbg2 = DTE.Debugger

        Dim attached As Boolean = False
        Dim proc As EnvDTE80.Process2
        For Each proc In DTE.Debugger.LocalProcesses
            If (Right(proc.Name, 8) = "calc.exe") Then
                proc.Attach2("native")
                attached = True
                Exit For
            End If
        Next

        If attached = False Then
            If attached = False Then
                MsgBox("calc.exe isn't running")
            End If
        End If
    End Sub
End Module

参照

参照

Process2 メンバ

EnvDTE80 名前空間

Process

その他の技術情報

オートメーション オブジェクト モデルの階層図