Pregunta

I am using UI Automation in a C# program. I have managed to acquire an element using its Automation ID. However, it exposes no patterns. Using UI Spy, I can see the text I want under Identification->Name. However, when I try to register an event to detect a change of text, nothing happens; the event handler does not get called.

UI Spy doesn't show any ControlPatterns. Does this mean I must manually poll for changes to the element's "name" or is there another way to do this?

¿Fue útil?

Solución

You'll have to implement this kind of event yourself, by manually polling the Name property, or rather continuously calling FindFirst with the old name, until it returns no result.

Licenciado bajo: CC-BY-SA con atribución
No afiliado a StackOverflow
scroll top