指定した項目で実行するコマンドの状態を取得します。
名前空間: Microsoft.VisualStudio.Data
アセンブリ: Microsoft.VisualStudio.Data (Microsoft.VisualStudio.Data.dll 内)
構文
'宣言
Public Overridable Function GetCommandStatus ( _
itemIds As Integer(), _
command As OleCommand, _
textType As OleCommandTextType, _
status As OleCommandStatus _
) As OleCommandStatus
public virtual OleCommandStatus GetCommandStatus(
int[] itemIds,
OleCommand command,
OleCommandTextType textType,
OleCommandStatus status
)
public:
virtual OleCommandStatus^ GetCommandStatus(
array<int>^ itemIds,
OleCommand^ command,
OleCommandTextType textType,
OleCommandStatus^ status
)
abstract GetCommandStatus :
itemIds:int[] *
command:OleCommand *
textType:OleCommandTextType *
status:OleCommandStatus -> OleCommandStatus
override GetCommandStatus :
itemIds:int[] *
command:OleCommand *
textType:OleCommandTextType *
status:OleCommandStatus -> OleCommandStatus
public function GetCommandStatus(
itemIds : int[],
command : OleCommand,
textType : OleCommandTextType,
status : OleCommandStatus
) : OleCommandStatus
パラメーター
- itemIds
型 : array<System.Int32[]
データ項目の識別子の配列はこのコマンドの呼び出しが必要である階層を表示します。
- command
型 : Microsoft.VisualStudio.Data.OleCommand
開始するコマンドを表す OleCommand のオブジェクト。
- textType
型 : Microsoft.VisualStudio.Data.OleCommandTextType
指定したコマンドの OleCommandTextType オブジェクトのインスタンス。
- status
型 : Microsoft.VisualStudio.Data.OleCommandStatus
指定したコマンドの OleCommandStatus オブジェクトのインスタンス。
戻り値
型 : Microsoft.VisualStudio.Data.OleCommandStatus
指定されたコマンドから返される状態を表す OleCommandStatus オブジェクトのインスタンスを返します。
例外
| 例外 | 条件 |
|---|---|
| ArgumentNullException | status、itemId や command のパラメーターが null です。 |
| ArgumentException | itemId パラメーターが無効です。 |
解説
このメソッドの呼び出し元は、コマンドの状態を保持する OleCommandStatus のインスタンスを割り当てます。このメソッドの実装では、このようなオブジェクトのプロパティを設定し、次に戻るには、同じ例に反映されます。
.NET Framework セキュリティ
- 直前の呼び出し元に対する完全な信頼。このメンバーは、部分的に信頼されているコードから使用することはできません。詳細については、「部分信頼コードからのライブラリの使用」を参照してください。