Forum Discussion

testcomplete's avatar
testcomplete
Occasional Contributor
14 years ago

How to map description to custom name using Name mapping?

Steps to map complete object description to custom name using name mapping (Also attached screenshot for more info)



Eg:

Object Description

Aliases.Printgroove_POD_Ready.HwndSource_CPGRMainWnd.CPGRMainWnd.grManinWindowGrid.sbEuropaStatusBar.StatusBarItem1.btnStatusPage.VisibleOnScreen

3 Replies

  • Hi,



    There're two ways to do this:

    1. Change the recorded names in the Name Mapping editor (see the "Name Mapping Editor" help topic) and modify your script.

    2. Map your objects manually before recording (see the "Name Mapping - Overview" help topic).
  • testcomplete's avatar
    testcomplete
    Occasional Contributor
    Hi,



    I want to replace the full description with a single custom name. Is that possible? if possible how?



    Eg:

    Object description

    Aliases.Printgroove_POD_Ready.HwndSource_CPGRMainWnd.CPGRMainWnd.grManinWindowGrid.sbEuropaStatusBar.StatusBarItem1.btnStatusPage.VisibleOnScreen



    I want to replace

     "Aliases.Printgroove_POD_Ready.HwndSource_CPGRMainWnd.CPGRMainWnd.grManinWindowGrid.sbEuropaStatusBar.StatusBarItem1.btnStatusPage" to "EuropaStatusBar" (single name) using name mapping



    then code becomes:



    EuropaStatusBar.VisibleOnScreen
  • Hi,



    You can drag aliases in the Name Mapping editor to any hierarchy level you need. See the "Changing the Mapped Objects' Hierarchy" and "Name Mapping Editor" help topics.