共用方式為


IAgentCommands::SetVisible

[Microsoft代理程式從 Windows 7 開始已被取代,而且可能無法在後續版本的 Windows 中使用。]

HRESULT SetVisible(
   long bVisible  // the Visible setting for Commands collection
);

設定 Commands 集合的 Visible 屬性值。

  • 傳回S_OK,表示作業成功。

bVisible

布爾值,決定 Commands 集合的 Visible 屬性。 True 會在顯示字元的快捷功能表時,將 Commands 集合 Caption 顯示;False 不會顯示它。

Commands 集合必須設定其 Caption 屬性,且其 Visible 屬性設定為 True,才能出現在字元的快捷功能表上。 Visible 屬性也必須設定為 True,讓集合中的命令在輸入作用中時出現。

另請參閱

IAgentCommands::GetVisibleIAgentCommand::SetCaption