Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Get Patterns like TogglePattern #1412

Open
bar-2 opened this issue Jan 11, 2021 · 1 comment
Open

Get Patterns like TogglePattern #1412

bar-2 opened this issue Jan 11, 2021 · 1 comment

Comments

@bar-2
Copy link

bar-2 commented Jan 11, 2021

Hi,
I would like to know if there is any possibility to get the patterns of a WindowsElement.
In the screenshot, I've added, you can see which value I would like to have of the TogglePattern. The element is a button in this case.
The Selected-Attribute of the WindowsElement of the button returns always false, so it seems that I need the ToggleState for checking if the button is selected, or not.
I also tried it with element.GetAttribute("TogglePattern") and element.GetAttribute("ToggleState"), but it always returns null, also when I use the GetProperty-method with this.
Beside that, it would make my life much easier if there is a way to access also the other patterns like ScrollPattern etc.

Anybody an idea?
pattern

@liljohnak
Copy link

@bar-2 each control is different. Toggle buttons and checkboxes use the .Selected property.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants