Micro Focus QTP (UFT) Forums
How to fetch the coordinates of a button and perfom the action - Printable Version

+- Micro Focus QTP (UFT) Forums (https://www.learnqtp.com/forums)
+-- Forum: Micro Focus UFT (earlier known as QTP) (https://www.learnqtp.com/forums/Forum-Micro-Focus-UFT-earlier-known-as-QTP)
+--- Forum: UFT / QTP Others (https://www.learnqtp.com/forums/Forum-UFT-QTP-Others)
+--- Thread: How to fetch the coordinates of a button and perfom the action (/Thread-How-to-fetch-the-coordinates-of-a-button-and-perfom-the-action)



How to fetch the coordinates of a button and perfom the action - venkatbatchu - 01-19-2010

Could you please refresh me with the below scenario?
Version : QTP 10 , O/S: Windows XP Service Pack 3
Hi,
Some data is displaying on the applicaion which is almost like Excel data

say for example 120 rows and 5 columns
My requirement is i will be searching for a string among the data available on the application.
it has to search on the application if it exists then it has to fetch the coordinates (x,y)


Note: All the data displayed on the application is not recongnised as "Java Table" or "Java Butoons" which is recongnosing as "Java Terminal View"


once i get the locaions then i will be performing the script like

Code:
JavaWindow("xxxxxx").JavaTerminalView("xxxxxxx").Click x,y
here x,y are the coordintes of the object

Note: I have done some work on this like
First:
Code:
object.GetTextLocaion
Second:
TextUtil.GetTextLocation

by using that i am getting the error message as "un recoverable error"

Please suggest me regarding this,

Thanks in advance,
Venkat.Batchu