Forum Discussion

dkasirajan's avatar
dkasirajan
Contributor
7 years ago
Solved

In object browser sometime names displays "WindowsForms10...." than Name and then test fails

In object browser sometime  names displays "WindowsForms10...." than Name and then test fails with object recognition  error. on restarting application or test complete . then testcomplete identifies name and scripts works. 

This issue happen. How to resolve it. 

Please find the attached screen shot

  • Use NameMappingRefresh before performing an action on the object, it may resolve your issue example as given below

     

      NameMapping.Sys.Refresh()
      NameMapping.Sys.RefreshMappingInfo()
      aqUtils.Delay(500)

     

      object,Click()

      //or any other operation

     

    small delay is required (or observed) to make it work smooth.

     

    Also try the below settings

    Options->Engines->Name Mapping->Update Name Mapping during test run

     

    Make that check box enable (Checked)

     

    Hope it may resolve your problem

     

  • I have added this code. this  problem happens occasionally   . i did n't this problem again. so i am not sure. Because earlier i used to refresh  object browser manually it did not solve problem. so let me check it for a while to see it happens or not.

    I really appreciate the response. Thanks.

    Devaki

8 Replies

  • Marsha_R's avatar
    Marsha_R
    Champion Level 3

    I've seen that happen occasionally and the only way we fixed it was by rebooting.  Seems like TestComplete forgets the name mapping every once in a while.  We couldn't reproduce it on demand so Support couldn't really help us.

    • pramoddn's avatar
      pramoddn
      Occasional Contributor

      Use NameMappingRefresh before performing an action on the object, it may resolve your issue example as given below

       

        NameMapping.Sys.Refresh()
        NameMapping.Sys.RefreshMappingInfo()
        aqUtils.Delay(500)

       

        object,Click()

        //or any other operation

       

      small delay is required (or observed) to make it work smooth.

       

      Also try the below settings

      Options->Engines->Name Mapping->Update Name Mapping during test run

       

      Make that check box enable (Checked)

       

      Hope it may resolve your problem

       

      • dkasirajan's avatar
        dkasirajan
        Contributor

        I have added this code. this  problem happens occasionally   . i did n't this problem again. so i am not sure. Because earlier i used to refresh  object browser manually it did not solve problem. so let me check it for a while to see it happens or not.

        I really appreciate the response. Thanks.

        Devaki

  • pramoddn's avatar
    pramoddn
    Occasional Contributor
    Did you try launching application via testedApps?
    • dkasirajan's avatar
      dkasirajan
      Contributor

      Usually i start application manually. On installation it is launched automatically. Then i ran test scripts.

      I will try starting application from the script.

      Thanks for the response,

      Devaki