Capturing Mouse movements

Best practices, code snippets for common functionality, examples, and guidelines.
kris123pra
Posts: 16
Joined: Fri Sep 17, 2010 8:13 am
Location: India

Capturing Mouse movements

Post by kris123pra » Thu Dec 02, 2010 4:22 am

Hi

Till now the work I have done using Ranorex is real great. Thanks for such a great tool!

I was wondering if I could record the mouse movements on a picture box. Since it is still in progress on our application, I gave a try on MSPaint.
Here is what I did -
-I started a recording,
-Opened mspaint application
-selected pencil
-started moving the mouse to draw something like SNA
-saved the image

Now when I replay this, I get a very bad image ..and I knew that it was working as expected. Since the recording takes only start and end positions. Passing pixel by pixel info is too much if there are many such letters to be types or say if the letter size needs to be changed.

But how do we overcome this? Any suggestions? As I mentioned, I need this for some workflows in our application.

Help appreciated!

Thanks
Kris

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

Re: Capturing Mouse movements

Post by Support Team » Thu Dec 02, 2010 5:13 pm

By default, Ranorex only records mouse up and down events. You can, however, record mouse moves to by enabling and pressing the 'M' hot key while recording. The more move points you record, the more similar will the replay be. See following section in the Ranorex User Guide for more information on hot keys:
http://www.ranorex.com/support/user-gui ... -keys.html

You can also combine this functionality with image-based automation/recording.

Does this help you for your use case?

Regards,
Alex
Ranorex Team
.
Image