Adding Silverlight custom controls

Ranorex Spy, Recorder, and Studio.
tsyingling
Posts: 20
Joined: Wed Nov 04, 2009 5:18 pm

Adding Silverlight custom controls

Post by tsyingling » Thu May 13, 2010 3:15 pm

I'm not a programmer so I'm hoping someone can translate and reply in a way that I can tell the programmers how to help me set up the Ranorex software for this. I've been using Ranorex Studio for about 6 months and have successfully been creating the Ranorex testing projects for a new product using that we're developing. As the programmers have been comfortable with developing in Silverlight, we're now using a number of custom Silverlight controls which are not being completely identified by the tracking tool, i.e. a mutil-select combobox or a combobox that has radio buttons in the dropdown which enable other text selections, etc. which are just coming up as a combobox so I can't identify all the properties I need to or that are available for the control like SelectedFirstName, etc. or even seeing the radio buttons. I read the blog about the "Enabling automation for 3rd party controls by adding Accessibility" which looks like is close to what I need to do and I'm going to foward to them. They're asking me if they simply(?) gave me dlls with the custom controls could I load them into Ranorex to allow Ranorex to recognize the controls. I think what they're asking about may be accomplished using the Add References function launching from the Studio Project view but I'm not sure what the step-by-step would be or if I'm even interpreting that function correctly. Also, is there anything unique in regards to custom Silverlight controls and Ranorex that I/they may need to know?

Hope this makes some sense and thanks.

User avatar
Support Team
Site Admin
Site Admin
Posts: 11709
Joined: Fri Jul 07, 2006 4:30 pm
Location: Graz, Austria

Re: Adding Silverlight custom controls

Post by Support Team » Fri May 14, 2010 10:07 am

In general, if your developers create their custom controls by composing standard Silverlight controls (the common best practice), these controls inside the custom controls can automatically be identified by Ranorex.

The only thing Ranorex can't automatically recognize are controls that are custom-drawn, e.g. shapes. In order to automate such controls as well, your developers need to extend the UIAutomation support of the custom controls! See the following MSDN page for more information: http://msdn.microsoft.com/en-us/library/cc165614.aspx
By doing that, Ranorex will get the information from the custom controls through UIAutomation; besides, that also improves the screen reader support of those controls. (See following forum thread for additional info: http://www.ranorex.com/forum/post4193.html#p4193)
tsyingling wrote:They're asking me if they simply(?) gave me dlls with the custom controls could I load them into Ranorex to allow Ranorex to recognize the controls. I think what they're asking about may be accomplished using the Add References function launching from the Studio Project view
Sorry, but that functionality is currently not available in Ranorex. The "Add References" can be used to add already existing functionality from testing libraries you created with Ranorex, see the following User Guide section: http://www.ranorex.com/support/user-gui ... rence.html

Regards,
Alex
Ranorex Team
.
Image