다음을 통해 공유


AutomationProperties.AutomationIdProperty 속성

정의

Automation 요소에 대한 UI 자동화 식별자(ID)를 포함하는 문자열인 AutomationProperties.AutomationId 연결된 속성을 식별합니다.

public:
 static property DependencyProperty ^ AutomationIdProperty { DependencyProperty ^ get(); };
static DependencyProperty AutomationIdProperty();
public static DependencyProperty AutomationIdProperty { get; }
var dependencyProperty = AutomationProperties.automationIdProperty;
Public Shared ReadOnly Property AutomationIdProperty As DependencyProperty

속성 값

AutomationProperties.AutomationId 연결된 속성의 식별자입니다.

설명

사용할 수 있는 경우 요소의 AutomationId는 로컬 언어에 관계없이 애플리케이션의 모든 instance 동일해야 합니다. 값은 형제 요소 간에 고유해야 하지만 전체 데스크톱에서 반드시 고유하지는 않습니다. 예를 들어 애플리케이션의 여러 인스턴스 또는 Windows Explorer 여러 폴더 보기에는 "SystemMenuBar"와 같은 AutomationId 속성이 동일한 요소가 포함될 수 있습니다.

AutomationId에 대한 지원은 항상 더 나은 자동화된 테스트 지원을 위해 권장되지만 이 속성은 필수는 아닙니다. 지원되는 경우 AutomationId 는 UI 언어에 관계없이 실행되는 테스트 자동화 스크립트를 만드는 데 유용합니다. 클라이언트는 다른 애플리케이션에서 노출하는 AutomationId 값에 대해 어떠한 가정도 하지 않아야 합니다. AutomationId 는 애플리케이션의 여러 릴리스 또는 빌드에서 안정적으로 보장되지 않습니다.

적용 대상