Clicking on a control/element : Automation API

Clicking on a control/element

Class library usage, coding and language questions.

Clicking on a control/element

Postby testMunky » Wed Jan 30, 2008 6:53 pm

Hi,

is there a way of 'clicking' a control or element without the use of the mouse?

I currently use the following:

Code: Select all
Mouse.ClickElement(element, MouseButtonType.LeftButton); or
Mouse.ClickControl(control, MouseButtonType.LeftButton);


I can't find an alternative in the help, but its been a long day and i may have just missed it! hehe

sorry for being lazy

:D
testMunky
 
Posts: 6
Joined: Wed Jan 16, 2008 12:52 pm
Location: Hants, UK

Postby Support Team » Thu Jan 31, 2008 11:42 am

If the control is a button, you can call Button.Click().
With an element Element.DoDefaultAction() should be the method you're searching for.

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


Return to Automation API

Who is online

Users browsing this forum: No registered users and 0 guests