Forum Discussion

aletsu's avatar
aletsu
Occasional Contributor
5 years ago

Why TestComplete and TestExecute recognizes objects differently.

if aqObject.CheckProperty(Sys.Process('MdataQ').VCLObject('DocumentSelectionView').VCLObject('pnlActiveDocs').VCLObject('cxOrderGrid').Window('TcxGridSite', '', 1).Window('TcxFindPanelMRUEdit', '', 1).Window('TcxFindPanelMRUEditInnerEdit', '', 1), 'Visible', cmpEqual, true) then
mdataQ.DocumentSelectionView.pnlActiveDocs.cxOrderGrid.TcxGridSite.TcxFindPanelMRUEdit.TcxFindPanelMRUEditInnerEdit.Keys(orderNr+'[Enter]');

 

TestComplete:

TestExecute:

 

 

 

  • Hi sonya_m,

     

    Yes, I did and unfortunately it did not work. I think I have not been able to explain well what the problem is. If you read my answer to Wamboo you may understand the problem.

  • In this case, if there is a fixed point in NameMapping, use the .find() function on it to dynamically find the object indicated in the topic.

  • Wamboo's avatar
    Wamboo
    Community Hero

    Hi,

     

    To work around this, you can use the conditional option inside NameMapping.

    Add an external condition "OR" for this object value.

     

    I mean, for example, if you need to have a value of class A and B within one object -> add it to the NameMapping condition.

    • aletsu's avatar
      aletsu
      Occasional Contributor

      Hi Wamboo

       

      Tnx for your answer,  

       

      We have a developing machine with TestComplete where we write test cases, then we have a Test server with TestExecute here we run out test cases. The application we test contents DevExpress's TcxGrid
      with TcxFindPanel that we tring to access here:

       

      application.DocumentSelectionView.pnlActiveDocs.cxOrderGrid.TcxGridSite.TcxFindPanelMRUEdit.TcxFindPanelMRUEditInnerEdit.Keys(orderNr+'[Enter]');

       

      The code above working perfectly in TestComplete but TestExecute fails to find the object.

      Im not shure then NameMapping will help here , but i'll try. 

      • Wamboo's avatar
        Wamboo
        Community Hero

        In this case, if there is a fixed point in NameMapping, use the .find() function on it to dynamically find the object indicated in the topic.