Forum Discussion

blbdt36's avatar
blbdt36
Contributor
9 years ago

XPOST - Incorrect cross reference error

I am getting a cross reference error that is incorrect.  I checked all the USEUNIT declarations of the referenced units and they do NOT reference each other, yet I am all of the sudden getting this error.  The even the line referenced in the error is blank.  If I delete a completely different USEUNIT reference, I don't get the error, but I need that reference.   And again, there is no cross reference issue when actually looking at the scripts

 

Why am I getting this error?

 

Cross-posting to try and actually get a response

4 Replies

  • cunderw's avatar
    cunderw
    Community Hero

    Have you checked ALL of your script units, not just the ones you're trying to use?

    • blbdt36's avatar
      blbdt36
      Contributor

       

      cunderw wrote:

      Have you checked ALL of your script units, not just the ones you're trying to use?


      I did that when I wasn't getting any answers.  With all the USEUNIT statements cleaned up, I was still getting the error.  It is caused by a specific function, but I don't see the reason for the Cross Reference issue.  When I move the function into one of the erroring Units, it is fine.  If I use the function outside of that Unit and add a Reference to it, error.

       

      I have a thread on StackOverflow that seems to have found the long, convoluted issue.

      http://stackoverflow.com/questions/34320500/testcomplete-incorrect-cross-reference-error/34328798#34328798

       

       

  • Ravik's avatar
    Ravik
    Super Contributor

    Hi,

     

    It may happen becouse you UNIT's may not associate correctly.

     

    Try below step, it may help you

     

    1- Right Click on your Script unit

    2- Click on Add unit Referances

    3- Select 'Add The following referances to ..........' (make sure all the check boxes are selected)

    4- Click OK

    5- again Select ' Add .......Unit referance to following Units (make sure all the check boxes are selected) 

    6- Click OK 

     

    • blbdt36's avatar
      blbdt36
      Contributor

      Ravik wrote:

      Hi,

       

      It may happen becouse you UNIT's may not associate correctly.

       

      Try below step, it may help you

       

      1- Right Click on your Script unit

      2- Click on Add unit Referances

      3- Select 'Add The following referances to ..........' (make sure all the check boxes are selected)

      4- Click OK

      5- again Select ' Add .......Unit referance to following Units (make sure all the check boxes are selected) 

      6- Click OK 

       


       

      I don't see how this would change anything since all my references are already entered.  Can you clarify what this would do besides add already existing USEUNIT references?