CommunityToolkit/WindowsCommunityToolkit

AutomationID not binding to control when set in XAML

Open

#3,204 创建于 2020年3月30日

在 GitHub 查看
 (1 评论) (0 反应) (0 负责人)C# (1,403 fork)batch import
accessibility :wheelchair:bug :bug:help wantedmarkdown 📑

仓库指标

Star
 (5,708 star)
PR 合并指标
 (30 天内没有已合并 PR)

描述

Describe the bug

A clear and concise description of what the bug is.

Setting the AutomationProperties.AutomationID in the XAML does not actually set the AutomationID of the control.

  • Is this bug a regression in the toolkit? If so, what toolkit version did you last see it work:

Steps to Reproduce

Steps to reproduce the behavior:

  1. Create a MarkdownTextBlock
  2. Set the AutomationProperties.AutomationID
  3. Observe using any testing framework or inspection tool to see the value is not set

Expected behavior

A clear and concise description of what you expected to happen.

I would expect the AutomationID to properly be set

Screenshots

If applicable, add screenshots to help explain your problem. This image shows the use of MarkdownTextBlock with the AutomationID set, but the inspection tool shows the property is not present image

This images shows that the inspection tool does properly work, as the AutomationID for the overview TextBlock is set, and you can see it present in the inspection tool window image

Environment

NuGet Package(s): 

Package Version(s): 

Windows 10 Build Number:
- [ ] Fall Creators Update (16299)
- [ ] April 2018 Update (17134)
- [ ] October 2018 Update (17763)
- [ X ] May 2019 Update (18362)
- [ ] Insider Build (build number: )

App min and target version:
- [ ] Fall Creators Update (16299)
- [ min ] April 2018 Update (17134)
- [ X ] October 2018 Update (17763)
- [ X ] May 2019 Update (18362)
- [ X ] Insider Build (xxxxx)

Device form factor:
- [ X ] Desktop
- [ ] Xbox
- [ ] Surface Hub
- [ ] IoT

Visual Studio 
- [ ] 2017 (version: )
- [ X ] 2019 (version: ) 
- [ ] 2019 Preview (version: )

Additional context

Add any other context about the problem here.

贡献者指南