Page 1 of 1

Is there a way to recognize Custom Controls ?

Posted: Thu Mar 08, 2007 3:11 pm
by Prashant
Does Ranorex provide an interface to implement a proxy kind of mechanism to recognise Custom Objects for MFC and .NET Based Applications?

After getting the control (Form.FindControlById()), is it possible to cast it to the particular custom type (adding a reference to the compiled class type for the custom control) so that we can get all the public properties and methods of the custom control?

It will be a great help if you can suggest directions for recognizing custom controls.

Posted: Thu Mar 08, 2007 9:56 pm
by webops
We implemented a proxy mechanism to set and get the properties of .NET controls, we use it in RanorexSpyPro.

This approach doesn't work with MFC applications, the testcode runs in an other process space and the properties and methods of the C++ classes cannot be riched, we communicate with windows messages.

The Ranorex element approach supports a general way to access every kind of control and control elements. It should also work with custom controls.
Please try RanorexSpy with your application.

Jenö

Posted: Mon Mar 12, 2007 8:27 am
by Prashant
Thanks for the clarification.

We were specifically looking for MFC applications. Would follow the suggested approach for .NET custom controls.

Posted: Mon Mar 12, 2007 11:06 pm
by webops
The Ranorex element approach works with both MFC and .NET controls.
It supports a general way to access every kind of control, it should also work with custom controls.

Jenö
Ranorex Team