> For the complete documentation index, see [llms.txt](https://chaoses-ib.gitbook.io/directory-opus/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://chaoses-ib.gitbook.io/directory-opus/manual/reference/scripting_reference/scripting_objects/items.md).

# Items

The **Items** object lets you enumerate a collection of one or more [**Item**](/directory-opus/manual/reference/scripting_reference/scripting_objects/item.md) objects. An **Items** object is retrieved from a number of methods and properties, including [**Dialog**](/directory-opus/manual/reference/scripting_reference/scripting_objects/dialog.md)**.Multi**, [**DOpus**](/directory-opus/manual/reference/scripting_reference/scripting_objects/dopus.md)**.GetClip**, [**Command**](/directory-opus/manual/reference/scripting_reference/scripting_objects/command.md)**.files** and several others.

| Property Name      | Return Type                                                                                             | Description                                                                                                                                                                                                                                                                                                                                                         |
| ------------------ | ------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| *\<default value>* | *collection:*[**item**](/directory-opus/manual/reference/scripting_reference/scripting_objects/item.md) | Returns a collection of [**item**](/directory-opus/manual/reference/scripting_reference/scripting_objects/item.md) objects that you can enumerate.                                                                                                                                                                                                                  |
| result             | *bool*                                                                                                  | When this **Items** object comes from the [**Dialog**](/directory-opus/manual/reference/scripting_reference/scripting_objects/dialog.md)**.Multi** method, it includes a **result** property giving the result of the dialog. The collection of items is only valid if **result** returns **True**. If it returns **False** it means the user cancelled the dialog. |

| Method Name  | **Arguments** | Return Type | Description                                                                                                                                                                                                                                                                                                                                                                            |
| ------------ | ------------- | ----------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| RemoveNested | *none*        | *int*       | Removes any nested items from the collection (items that came from sub-folders rather than the root folder). The number of items removed is returned.                                                                                                                                                                                                                                  |
| Update       | *none*        | *none*      | Updates the state of this object. This only applies to collections that come from certain sources (e.g. from a [**Tab**](/directory-opus/manual/reference/scripting_reference/scripting_objects/tab.md)). When the **Items** object is first retrieved, a snapshot is taken. Changes made after that outside of the script will not be detected unless you call the **Update** method. |
