---
title: "getParent"
canonical: "https://help.vicon.com/space/ShogunPost121/1253737101/getParent"
format: markdown
---
# Description

Retrieves the parent of a module. If the module has no parent, and empty string, "", is returned.

## Functional area

Data retrieval

# Command syntax

## Syntax

> Macro (scroll-tablelayout)

|  |
| --- |
| `getParent module [-fullPath] [-nameOnly]` |

### Arguments

| Name | Type | Required | Comments |
| --- | --- | --- | --- |
| `moduleName` | string | yes | The module to get parent for. |

### Flags

| Name | Flag arguments | Argument type | Exclusive to | Comments |
| --- | --- | --- | --- | --- |
| `fullPath` | 0 | — | nameOnly | — |
| `nameOnly` | 0 | — | fullPath | — |

## Return value

string

> Macro (scroll-pagebreak)

## Examples

```plaintext
// Get the parent of the "rhumerus".
string $parent;
$parent = `getParent "rhumerus"`;
print $parent;
```

# Additional information

## Related commands

- [getChildren](https://vicon-help.atlassian.net/wiki/spaces/ShogunPost121/pages/1253738310)
- [getModules](https://vicon-help.atlassian.net/wiki/spaces/ShogunPost121/pages/1253736739)
- [parent](https://vicon-help.atlassian.net/wiki/spaces/ShogunPost121/pages/1253740387)
- [unparent](https://vicon-help.atlassian.net/wiki/spaces/ShogunPost121/pages/1253739671)