Forum Discussion

jkrolczy's avatar
jkrolczy
Super Contributor
10 days ago
Solved

Ctrl-Click Navigation issue to correct location of declaration\routine

I am using TC 15.76 and tried this on TC15.74 - same issue

When in my automation fwk, the ability to ctrl-click on function name and taken to where it is declared is being flakey.

A majority of my test scripts direct me correctly, but I have a few that direct me to the top of my test script and not to the correct location of declaration\routine.

Here is a portion of how I call the test scripts in my package:

    // Module Testing
    // ----------------------   
    RTC538124();  - ctrl-click correctly to the declaration location of function\routine    
    TC538453();   - issue with ctrl-click  
    RTC538659();  - ctrl-click correctly to the declaration location of function\routine 
    TC537950();   - ctrl-click correctly to the declaration location of function\routine

 

Here is a portion of my test script:

//USEUNIT RM_CommonFunctions   (ctrl-click incorrectly takes me here)
//USEUNIT RulesManagerMainWindowFunctions
//USEUNIT RM_ManageUsersWndFunctions
//USEUNIT RM_MainMenuFunctions
//USEUNIT RM_TabFunctions
//USEUNIT NEW_RM_Job_Monitor
//USEUNIT NEW_RM_SearchEdits_Modules
//USEUNIT NEW_RM_ModuleWorkSpace
//USEUNIT RM_VersionHistoryWindow

// ================================================
// Function: TC538124() - qTCID 50
//
//
// Edited by : 
//
// Description:
//   This script performs that following steps:
//
//
// ================================================

function TC538453()   (ctrl-click should take me here)
{
  // --- Results File Name ---
  var DateTimeLabel = getFileNameDateTimeLabel();

...

 

When I try to run a package of scripts, when executing this test script in the package, it provides the following error:

Object doesn't support this property or method

How can I correct this ctrl-click function issue to find the declaration\rountine correctly ?

When in this test script, the routine textbox is blank when doing the ctrl-click.
The dropdown for the Desired Routine area does contain the test script function name.

Anyone seen this?

Have a suggestion or solution to before I open a Support ticket?

 

 

 

  • The above suggestions did not correct my issue.

    Playing with this issue more and remembering a long, long time ago.

    When I had code modules and the function\methods named the same like above,
    this issue would be seen.

    The way I corrected it was to either rename the code module or the function\method name.

    This would clear up the issue and allow ctrl-click navigation to work correctly.
    A little bug here?

    Auto fwk adjusted and code checked in.
    All working now. 

3 Replies

  • jkrolczy's avatar
    jkrolczy
    Super Contributor

    The above suggestions did not correct my issue.

    Playing with this issue more and remembering a long, long time ago.

    When I had code modules and the function\methods named the same like above,
    this issue would be seen.

    The way I corrected it was to either rename the code module or the function\method name.

    This would clear up the issue and allow ctrl-click navigation to work correctly.
    A little bug here?

    Auto fwk adjusted and code checked in.
    All working now. 

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

    You're likely seeing the Ctrl+Click issue because TestComplete isn't correctly indexing the TC538453() function. Even though it's declared properly, possible causes include:

    • Project parsing issues
    • Corrupted script index
    • File encoding (use UTF-8 without BOM)
    • Missing or incorrect //USEUNIT reference

    Fixes to try:

    1. Close TestComplete completely
    2. Delete .tcLS files from the project folder (these cache script state)
    3. Restart TestComplete
    4. Open the project, then use File > Save All to rebuild references
    5. Ensure TC538453() is uniquely declared (not duplicated)
    6. Confirm proper //USEUNIT usage if calling from another script
    7. Check script file is UTF-8 encoded without BOM and cleanly formatted

    If Ctrl+Click still doesn't work, try isolating the function in a minimal test. If the issue persists, open a SmartBear support ticket with project details.

    🤖 AI-assisted response.
    💬 Found the answer helpful? Give it a Kudos by clicking Like!
    ✅ Got your issue resolved? Click Mark as Solution so others can find it quickly.

  • jkrolczy's avatar
    jkrolczy
    Super Contributor

    Also,

    I can go directly to the code for this test script:  TC538453()

    And run the script directly with no issues.