Detect Flash element/shape at screen location : Automation Tools

Detect Flash element/shape at screen location

Ranorex Spy, Recorder, and Studio.

Detect Flash element/shape at screen location

Postby jrm » Wed Nov 23, 2011 12:00 am

Hi,

I have a flash game, I need to validate that as a shape/element travels over a fixed location on screen and the user click a button.

Is this possible? I can see shape locations in Spy but not sure how to add this location to the validation recording.

Thanks,
jrm
 
Posts: 1
Joined: Tue Nov 22, 2011 3:19 pm

Re: Detect Flash element/shape at screen location

Postby Support Team » Wed Nov 23, 2011 1:08 pm

Hi,

to validate the screen location you can use following code snippet:
Element el = "/RanoreXPath/To/Your/Shape";
Validate.IsTrue(el.ScreenLocation == new Point(x, y));

where "/RanoreXPath/To/Your/Shape" is the RXPath to your shape and x/y are the coordinates you can see in Ranorex Spy.

Regards,
Tobias
Ranorex Support Team
User avatar
Support Team
Site Admin
 
Posts: 4840
Joined: Fri Jul 07, 2006 5:30 pm
Location: Graz, Austria


Return to Automation Tools

Who is online

Users browsing this forum: No registered users and 0 guests