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

Returns a value of true or false depending on whether or not the indicated module is selected.

This command is only used with objects, not strings, as the command is only relevant if the object exists (if the object does not exist, it is not relevant to determine its status of being selected vs. not).

## Functional area

Data retrieval

# Command syntax

## Syntax

> Macro (scroll-tablelayout)

|  |
| --- |
| `isSelected module` |

### Arguments

| Name | Type | Required | Comments |
| --- | --- | --- | --- |
| `module` |  |  | Name of the module in the scene that you wish to query. |

### Flags

None 

## Return value

boolean

> Macro (scroll-pagebreak)

## Examples

```plaintext
// Here are 3 versions of syntax that are equally valid 
// and return the same information
boolean $x = Actor_1.isSelected();
boolean $y = isSelected( Actor_1 );
boolean $z = `isSelected Actor_1`;
print $x $y $z;
```

# Additional information

## Related commands

- [exists](https://vicon-help.atlassian.net/wiki/spaces/ShogunPost121/pages/1253739155)
- [hasKey](https://vicon-help.atlassian.net/wiki/spaces/ShogunPost121/pages/1253738339)