Forum Discussion

swapnalinarkar's avatar
swapnalinarkar
Occasional Contributor
8 years ago

Application process gets closed when I enter window class in Text Recognition on 64 bit sys

Hi,

 

I am using Test Complete tool v 10 . Desktop module. I have installed test complete on 64 bit system but when i enter the class in Text Recognition window and try to run the script then my application gets closed.

However if I run the same script with above setting then on 32 bit system then it's running perfectly.

 

If I remove the class name from Text recognition window then application wont get closed but my script get s failed as tool is unable to find object using text recognition.

 

Is there any setting that need to be done on 64 bit system to recognise the objects using text recognition.

 

Waiting for reply as most of my script contain text recognition.

 

Thanks,

Swapnali

4 Replies

    • swapnalinarkar's avatar
      swapnalinarkar
      Occasional Contributor

      I cannot share the code due to security reason. But its in following format

       

      var gridWindow = Sys.Process("Our Project Application Name").SWTObject("Composite", "").etc

       

      Above code recognise parent window of our application. There are child window / tabs which i recognised using Text Recognition.

       

      So for Ex: my parent window class is suppose 'SWT_Window0'. So i have given this class name in Text recognition.

      Now I m clicking one of my child window as - gridWindow.TextObject("OurChildWindowName").Click();

       

      Here my application automatically gets closed.

       

      After debugging it seems that if i do not run the script and just enters the class name in Text recognition window and tried to find the object using object spy then also my application gets closed. This issue is observed only on 64 bit Windows 7 system same thing is working on 32 bit Win 7.

       

      Thanks in Advance,

      Swapnali

      • tristaanogre's avatar
        tristaanogre
        Esteemed Contributor

        Is there a reason why you need to use TextRecognition?  While it works to give you access to things based upon the text labels on screen, it's really not the best way to access stuff on an object.

         

        Since your object is recognized as a SWTObject, you should be able to access native properties and methods of your object to perform the tasks of clicking on tabs, etc., within the object.  Have you tried investigating those areas of your object? 

         

        Probably a better solution would be to see if you can map your class to one of the already supported classes in your project | object mapping pane. Investigate your object again and look for WndClass, ClassName, ClrFullClassName, JavaFullClassName or QtClassName.  You can then map the class and potentially get better reognition.  See https://support.smartbear.com/testcomplete/docs/testing-with/object-identification/improving/mapping.html

         

        As to why you're having the problem you're having, my guess is that TC is somehow interacting improperly with your object because of the TextRecognition wrappers put around it.  TC is a 32-bit application so if it's trying to put 32-bit stuff around a 64-bit app, that could potentially cause issues.  Again, try the Object Mapping solution or using native methods and properties to be able to click on the tabs, etc., that you need