How to get automation ids of items in a itemscontrol?
Answer Posted / Durgesh Kumar
To get the AutomationIds of items in an ItemsControl, you can use the AutomationPeer.GetAutomationIdProperty method. However, ItemsControl does not provide automatic support for getting AutomationIds. You need to implement IInputElementProvider interface and override the GetFirstChildCore and GetLastChildCore methods to get access to each child element's AutomationPeer and retrieve its AutomationId.
| Is This Answer Correct ? | 0 Yes | 0 No |
Post New Answer View All Answers
No New Questions to Answer in this Category !! You can
Post New Questions
Answer Questions in Different Category