LDTP  3.5.0
 All Pages
grabfocus

Syntax

grabfocus('<window name>'[, '<component name>'])

Description

gives focus to the specified context or component, in case of a text box the cursor is placed in it.

ImplementationDetails

Return values
1on success, else LdtpExecutionError exception

Example

With respect to gnome search tool structure

settextvalue('SearchforFiles', 'txtNameContainsEntry')

This places the cursor in the 'txtNameContainsEntry' field.



Linux Desktop Testing Project