Answered by:
WPF Application not able to extract InnerText from WPF Button using Coded UI in VS2010

Question
-
Hi,
I am facing an issue that I am automating a WPF application in coded UI using VS 2010. When i try to capture the InnerText of the WPF button shown above, the InnerText is not caught as there is no property except Automation Id and Friendly Name and the Control has no children. Moreover, I do not have the access to Codebase for this Project.
Could anyone inform how to extract the InnerText including the Visit ID, Account ID, Admission, Patient Class, Attending Physician(s) etc? Or does Microsoft have any third party plugins for related issues?
Is an up gradation to VS 2012/2013 or any latest version useful?
Would appreciate an early response.
Thursday, May 7, 2015 11:01 AM
Answers
-
Hi,
I can see from here: https://msdn.microsoft.com/en-us/library/dd380742(v=vs.100).aspx
that WPF should be fully supported:
WPF 3.5 and later
Fully supported
Note
NetFx controls are fully supported, but not all third-party controls are supported.However, this does not mean that all the properties you expect will be supported.
Add the assertion that you have in your example (for any properties) and then investigate the code to see if there are any other properties that are not listed in the Coded UI Test Builder.
Hope this helps,
- Marked as answer by Jack Zhai-MSFTMicrosoft contingent staff Monday, May 18, 2015 11:47 AM
Thursday, May 7, 2015 2:55 PM -
Thanks for Dominic Wate's help.
Hi Amitesh Marwah,
I agree with Dominic's suggestion, we would check that whether we could add the assertion on the specific control, and then check whether it could capture the specific properties. If not, it means that the coded UI test doesn't support it. Generally we would write the extension for them.
Reference:
http://blogs.msdn.com/b/gautamg/archive/2010/01/05/series-on-coded-ui-test-extensibility.aspx
Best Regards,
Jack
We are trying to better understand customer views on social support experience, so your participation in this interview project would be greatly appreciated if you have time. Thanks for helping make community forums a great place.
Click HERE to participate the survey.- Marked as answer by Jack Zhai-MSFTMicrosoft contingent staff Monday, May 18, 2015 11:47 AM
Monday, May 11, 2015 5:31 AM
All replies
-
Hi,
I can see from here: https://msdn.microsoft.com/en-us/library/dd380742(v=vs.100).aspx
that WPF should be fully supported:
WPF 3.5 and later
Fully supported
Note
NetFx controls are fully supported, but not all third-party controls are supported.However, this does not mean that all the properties you expect will be supported.
Add the assertion that you have in your example (for any properties) and then investigate the code to see if there are any other properties that are not listed in the Coded UI Test Builder.
Hope this helps,
- Marked as answer by Jack Zhai-MSFTMicrosoft contingent staff Monday, May 18, 2015 11:47 AM
Thursday, May 7, 2015 2:55 PM -
Thanks for Dominic Wate's help.
Hi Amitesh Marwah,
I agree with Dominic's suggestion, we would check that whether we could add the assertion on the specific control, and then check whether it could capture the specific properties. If not, it means that the coded UI test doesn't support it. Generally we would write the extension for them.
Reference:
http://blogs.msdn.com/b/gautamg/archive/2010/01/05/series-on-coded-ui-test-extensibility.aspx
Best Regards,
Jack
We are trying to better understand customer views on social support experience, so your participation in this interview project would be greatly appreciated if you have time. Thanks for helping make community forums a great place.
Click HERE to participate the survey.- Marked as answer by Jack Zhai-MSFTMicrosoft contingent staff Monday, May 18, 2015 11:47 AM
Monday, May 11, 2015 5:31 AM