Skip to content

verifyCursorPosition (UI Automation - Interrogation)

  • Purpose
  • Generated from getCursorPosition(locator)
  • Retrieves the text cursor position in the given input element or text area beware, this may not work perfectly on all browsers. Specifically, if the cursor/selection has been cleared by JavaScript, this command will tend to return the position of the last location of the cursor, even though the cursor is now gone from the page. This method will fail if the specified element isn't an input element or text area, or there is no cursor in the element.
  • Syntax
  • verifyCursorPosition(locator, pattern)
  • Target
  • locator - an element locator pointing to an input element or text area.
  • Value
  • Pattern - The cursor position to be verified.
  • Return Value
  • The numerical position of the cursor in the field.
 
 
 

Feedback and Knowledge Base