No access to Flex application

Ranorex Spy, Recorder, and Studio.
Waterman
Posts: 5
Joined: Tue Jul 24, 2012 12:23 pm

No access to Flex application

Post by Waterman » Tue Jul 24, 2012 1:07 pm

Hi

I want to use Ranorex 3.3 for testing a Java application which uses Adobe Flex as UI. My IDE is eclipse.

For using Ranorex, I load the Ranorex Lib in the Flex application. For this
I add following line to the the compiler argument in the eclipse settings (under Flex Compiler):

-include-libraries "C:\Program Files\Ranorex 3.X\Bin\RanorexAutomation.swc"

I also add the Ranorex init call described under http://www.ranorex.com/support/user-gui ... sting.html ( RxAutomation.Init(); )

After starting a Ranorex test, Ranorex has no access to the Flex components of my application.
I get following error message:

[Warn ][Adobe Air]: Please make sure that you have correctly instrumented your AIR application. Otherwise Ranorex is not able to access UI objects inside your AIR application.

The following website provides more information on this technology limitation: http://www.ranorex.com/support/user-gui ... sting.html (This message is only shown once per report.)

[Warn ][Java AWT/Swing]: Please make sure that you have correctly instrumented your Java installation or application. Otherwise Ranorex is not able to access UI objects inside your Java AWT/Swing application.

The following website provides more information on this technology limitation:
http://www.ranorex.com/support/user-gui ... tions.html(This message is only shown once per report.)

What could be the failure? Which settings have to be made furthermore?

Thanks

Uli

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

Re: No access to Flex application

Post by Support Team » Tue Jul 24, 2012 3:01 pm

Hi,

have you instrumented the Adobe Flash/Flex and/or Java AWT/Swing technology via the Ranorex Instrumentation Wizard?

See Instrumentation Wizard

Kind Regards,
Larissa
Ranorex Support Team
.
Image

Waterman
Posts: 5
Joined: Tue Jul 24, 2012 12:23 pm

Re: No access to Flex application

Post by Waterman » Wed Jul 25, 2012 8:38 am

My Flex application is no web application. So I selected the option 'Java AWT/Swing'.
I think, the option 'Adobe Flash/Flex' is only usable for Flex web applications. In spite of I tried the option 'Adobe Flash/Flex' and installed the flash debug player for Internet Explorer and enabled the Preloader.
But the error message is still the old one.
Are there other possibilites to configure Ranorex?

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

Re: No access to Flex application

Post by Support Team » Wed Jul 25, 2012 11:43 am

Hi,

It seems that your AIR application isn't instrumented correctly. Have you done all the steps described in "Adobe Flex: Load the Ranorex Lib into your Flex application"?
Which version of AIR do you use?
Did the compilation went well after including the library and import RxAutomation?
Do you have saved the changes and restarted Flex and Ranorex?
Anymore details what you have tried would be much appreciated.

Regards,
Larissa
Ranorex Support Team
.
Image

Waterman
Posts: 5
Joined: Tue Jul 24, 2012 12:23 pm

Re: No access to Flex application

Post by Waterman » Wed Jul 25, 2012 1:05 pm

Hi Larissa,

I use Adobe Air 3.1 and Flex 4.6. The compilation went well after including the library and import RxAutomation. After starting my Flex application, I found also the following message in the log output:

Ranorex: playerType: Desktop
Ranorex: begin AIR setup
Ranorex: try initialize server socket
Ranorex: AIR listen error:SecurityError: Error #3205: Only application-sandbox content can access this feature.
Ranorex: check if setup external interface needed

This could be the failure. How can I fix it?

Best regards,

Uli

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

Re: No access to Flex application

Post by Support Team » Thu Jul 26, 2012 10:50 am

Hi Uli,

One thing you can try is to disable the Preloader: Tools - Instrumentation Wizard - Adobe Flesh/Flex - un-tick "Enable Ranorex Preloader Instruemtation" (also un-tick the installation options, since they are already installed)

If this don't work check again if all your manual changes for the instrumentation are made at the right place.

Kind regards,
Larissa
Ranorex Support Team
.
Image

Waterman
Posts: 5
Joined: Tue Jul 24, 2012 12:23 pm

Re: No access to Flex application

Post by Waterman » Fri Jul 27, 2012 10:40 am

Hi Larissa,

I checked my application again. The following call does not work correctly:

import Ranorex.RxAutomation;
RxAutomation.Init();

After changing the init method call and I can access on the Flex application.

import Ranorex.RxAutomationAir;
Ranorex.RxAutomationAir.Init();

Please modify your documentation.

Best regards,

Uli

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

Re: No access to Flex application

Post by Support Team » Mon Jul 30, 2012 12:19 pm

Hi,

I'm glad to hear that it's working now. I also have to tell you that there is no bug in our documentation. It should work (we also tested it and it worked as expected) with
import Ranorex.RxAutomation;
RxAutomation.Init(); .

You can also use
import Ranorex.RxAutomationAir;
Ranorex.RxAutomationAir.Init();
but it may be that there are some restrictions when implementing more sophisticated things with air.

We weren't able to reproduce your described behavior. Nevertheless we are interested in why "import Ranorex.RxAutomation" doesn't work in your case. If you also want this to be figured out please send us an example etc.

Kind Regards,
Larissa
Ranorex Support Team
.
Image