Forum Discussion

mrezahoseini's avatar
mrezahoseini
Contributor
11 years ago

can't play back a script

I have got a form, which has got a toolstrip. This formcan't playback, although it has got its namemapping has been recorded.

What shall I do??

 

 

 

7 Replies

  • Marsha_R's avatar
    Marsha_R
    Icon for Champion Level 3 rankChampion Level 3

    Are you saying that you have recorded a test that does something with a toolstrip?  What happens when you try to play the test back?  Do you get an error message, if so, what?

     

    You need to provide more details about what's happening before we can help.

  • I have a form like this

     

    2015-06-17_12-29-05.jpg

     

     

    this form has name mapping like this and left side is a toolstrip:

     

    2015-06-17_12-31-45.jpg

     

    my script is like this :

     

    toolStrip = AppType.frmGroup.tableLayoutPanel1.modernToolStripHolder1.toolStrip1;
    toolStrip.ClickItem("جستجو");

     

    when ever I would like to run this script, it couldn't and shows me error like this : 

     

     

    2015-06-17_12-34-24.jpg

    • Marsha_R's avatar
      Marsha_R
      Icon for Champion Level 3 rankChampion Level 3

      Okay, there are a few things to check.  

       

      Look down at the bottom of the error log for the Picture tab and see if there's anything useful there.

       

      Also look behind your app window and see if another window has opened behind that might be distracting TestComplete.

       

      Third, check in Task Manager and make sure there's not another copy of your app running.  

  • Also, you can try to enable "Ignore unexpected window". to do this go to Tools>>>Current Properties>>>Playback>>>Ignore unepxcted window

    • mrezahoseini's avatar
      mrezahoseini
      Contributor

      unfortuanately, my problem hasn't been solved yet. although it has got its name mapping, but for playing back, nothing important occures..

       

      for example, I have a "Save as Dialoug", with "yes" and "no" button, the script is clicking on "yes" button, but nothing happens.

       

      what shall I do??

       

      Thanks 

       

       

      • leandroaraujoso's avatar
        leandroaraujoso
        Contributor

        mrezahoseini wrote:

        unfortuanately, my problem hasn't been solved yet. although it has got its name mapping, but for playing back, nothing important occures..

         

        for example, I have a "Save as Dialoug", with "yes" and "no" button, the script is clicking on "yes" button, but nothing happens.

         

        what shall I do??

         

        Thanks 

         

         


        Hello mrezahoseini,

         

        Pay close attention to that "yes" button NameMapping. I think the problem might the outcome of a bad/wrong mapping, to check that, please:

         

        1 - Open that "Save as Dialog" manually;

        2 - Go to the its respective namemapping;

        3 - Right-click the namemapping and choose the "Highlight on screen" option;

        4 - Do the same thing for the "yes" button

         

        Let me know what happen. I hope this helps.

         

        Regards,

         

        Leandro de Araújo Souza

         

  • perhaps open a SmartBear support request ticket