Manage repository items | Ranorex Studio User Guide
Help CenterUser GuideRanorex Studio fundamentals

Managing repository items

Once they’re part of your repository, repository items can be edited and managed in various different ways. In this chapter, you’ll find out what options there are and what they do.

In this chapter

    Rename repository items

    Ranorex assigns repository items names automatically based on what the corresponding UI elements are called within the tracked application. Sometimes, these names can be cryptic or too generic, making it hard to navigate the repository. You can rename repository items to make it clearer what they do.

    Renaming repository items

    Renaming repository items

    Select the repository item and press F2.
    Rename the repository item and press Enter.
    The name of the repository item has been changed.

    Copy/move/delete repository items

    Repository items can be copied, moved, and deleted as usual. However, moving and deleting can cause issues if:

    • you move repository items across logical boundaries in the repository.
    • you delete repository items that are linked to one or more actions.

    Moving across logical boundaries

    Ranorex organizes repository items in logical groups called folders. A folder always contains references to UI elements which share the same base position in the UI. This concept is explained in detail in the next chapter.

    When you move a repository item from one folder to one with a different base path, you also alter the repository item’s base path. As a result, Ranorex likely won’t be able to find the UI element anymore and any actions linked to this repository item will fail during test execution. Ranorex will ask you for confirmation when you attempt to move an item in such a way.

    Moving repository items through RanoreXPath barriers

    Moving repository items across logical boundaries

    When you move a repository item from one folder to another with a different base path…
    …Ranorex will inform you about the consequences and ask you for confirmation.

    Note icon


    This only applies to app folders and rooted folders. Simple folders are not affected because they don’t have a base path.

    Deleting a linked repository item

    When you delete a repository item that’s linked to one or more actions, the actions will stop working. If you want to remove unused repository items, use the Cleanup function instead

    Deleting a repository item

    Deleting a repository item

    Select a repository item and delete it.
    The repository item is removed from actions it was linked to. The actions won’t work anymore.

    Update screenshot

    When a repository item is created, a screenshot of the corresponding UI element is also saved. It can be viewed in the repository. When the UI element changes in appearance, you may need to update it. The option Update screenshot allows you to do this quickly without having to retrack the UI element.

    Updating a repository item screenshot

    Updating a repository item screenshot

    Update screenshot option

    • Right-click the repository item whose screenshot you want to update
    • Click Update screenshot

    The screenshot

    Failure message

    • The screenshot can only be updated if the path for the UI element is still valid and the containing application is running, with the UI element visible. If this isn’t the case, an error message is displayed.

    Highlight element

    Sometimes it can be hard to tell which UI element a repository item references exactly. When you click Highlight element, Ranorex will highlight the UI element in the containing application. Of course this will only work if Ranorex can find the element, i.e. if the containing application is running and the path to the element is correct.

    Highlighting a repository item

    Highlighting a repository item

    Highlight element

    • Right-click the desired repository item.
    • Click Highlight element.

    The UI element is highlighted in the application for a few seconds with a blinking red frame.

    Search for corresponding UI-element

    Search for corresponding UI-element

    Search for the corresponding UI element

    • Sometimes Ranorex may take a while to find the corresponding UI element.
    • If the path is incorrect or the containing application hasn’t been started, Ranorex won’t be able to find the element.

    Add validation screenshot

    Ranorex normally creates screenshots for Validation actions automatically. However, sometimes you may want to save an additional validation screenshot for a repository item. The option Add validation screenshot lets you do this.

    Creating a validation screenshot

    Creating a validation screenshot

    Right-click the desired repository item.
    Click Add validation screenshot.
    The screenshot is saved to the repository item.

    Save screenshot

    You can save screenshots stored with repository items to any destination on your system. You can then restore the saved screenshot using the ⇢ image editor.

    Saving a repository screenshot

    Saving a repository screenshot

    Right-click the screenshot and click Save screenshot…

    Repository item properties

    Each repository item also has a set of properties that can be configured in its Properties panel.

    Opening repository item properties

    Opening repository item properties

    Right-click the desired repository item.
    Click Properties.
    The properties open to the right of the repository.

    List of properties

    Absolute path Represents the path to the repository item including the paths of all parent folders. Read-only.
    Adapter type Lets you select the adapter type. By default, Ranorex will automatically select the most appropriate adapter.
    Effective timeout The sum of all search timeouts applied to the specific repository item and all its parent folders. Read-only.
    Comment Lets you add a comment to the repository item.
    Live element The live element is the path of the repository element at the time it was added to the repository. This data will be gone after closing and reopening the Ranorex solution.
    Name The name of the repository item.
    Search timeout Defines the amount of time Ranorex will search for an element before an exception is thrown.
    Use ensure visible When set to Yes, forces the UI element to become visible before automation.