Forum Discussion

mrouse's avatar
mrouse
Contributor
14 years ago

How can I use hotspots without coordinates

Hi,



I am testing a Delphi app, at the GUI level (Keyword) and in one of the tests I select a text link, that I found out was a mapped hotspot, and it records the coodinates of the mouseclick into my test.  This isn't an issue until the app places additional info on screen which changes the coordinates of the text I clicked in my recording.  Since the text is a mapped hotspot I can't use the spy tool to find its object info.  Does anyone know of a way I can automate this without using coordinates.



Thanks in advance for any advice/help.



Mike

4 Replies

  • Robert,



    Thanks for the reply.  I did look into the Text recognition, at your suggestion, but it requires the use of the object properties.  I can't use the object spy to get any object info because the object spy doesn't see it.  I am assuming that the developer used hotspots because when you mouse over the test the text changes color and is underlined similar to a link on a web page.



    Thanks,



    Mike
  • tristaanogre's avatar
    tristaanogre
    Esteemed Contributor
    Actually, as far as I know, Text Recognition doesn't rely on properties necessarily...  All you need to do is put the window or form that contains the hotspots into the Text Recognition list.  Supposedly, you should be able to reference at least that much of the component (especially for a Delphi application).  Then, any Text objects within that panel can simply be referenced by "TextObject("Text string here")".



    So, while you can't get the properties of the hot spots, you can get the properties of the component on which the Hot spot resides and TestComplete takes it from there.
  • Robert,



    Thanks, so much.  I misunderstood the documantation and I thought I needed to have the object name of the hotspot object, which doesn't exist, instead of the name of the window containing the text.  The application I am working with has tons of these hotspots and this will save me soooooo much time.  Thanks so much. You are a life saver.



    Mike