AutomationElement.AutomationElementInformation.ControlType 屬性

定義

取得項目的 ControlType

public:
 property System::Windows::Automation::ControlType ^ ControlType { System::Windows::Automation::ControlType ^ get(); };
public System.Windows.Automation.ControlType ControlType { get; }
member this.ControlType : System.Windows.Automation.ControlType
Public ReadOnly Property ControlType As ControlType

屬性值

這個項目的互動模型。 預設值是 Custom

備註

控制項類型描述任意 UI 自動化元素的已知互動模型,而不需要依賴當地語系化控制項類型或複雜邏輯規則的組合。

唯一可以在執行時間變更這個屬性的情況,是針對支援 MultipleViewPattern 的控制項。 例如,Win32 ListView 控制項可以根據目前的檢視,從 DataGrid 變更為 List

如需詳細資訊,請參閱ControlTypeProperty

適用於

另請參閱