> ## Documentation Index
> Fetch the complete documentation index at: https://docs.abbyy.com/llms.txt
> Use this file to discover all available pages before exploring further.

# IUserAttachments

> Manage document attachment files in FlexiCapture scripts with the IUserAttachments collection: add, get, delete, and check attachments by name.

## What it does

A collection of the [IUserAttachment](/flexi-capture/appendix/scripts/iattachment) objects.

<a id="webverificationavailableinterface" />

<Note>
  Some methods and properties of this object are not available on the Web Verification Station for checking rules locally. The methods and properties that are not supported are marked with an asterisk (\*).
</Note>

## Methods

<table width="100%"><thead><tr><th style={{textAlign: 'left'}}><p><strong>Definition</strong></p></th><th style={{textAlign: 'left'}}><p><strong>Description</strong></p></th></tr></thead><tbody><tr><td><p>AddNew( name : string) : <a href="/flexi-capture/appendix/scripts/iattachment">IUserAttachment</a> <a href="#webverificationavailableinterface">\*</a></p></td><td><p>Creates a new attachment file and starts editing it.</p><p><strong>Important! </strong> The method creates a new <a href="/flexi-capture/appendix/scripts/iattachment">IUserAttachment</a> item without adding it to the collection. To add the item to the collection and make it available for editing, the UploadAttachment( ) method must be called.</p><p><strong>Note: </strong> If a non-zero attachment with this name already exists, an exception will be returned.</p></td></tr><tr><td><p>Delete( name : string) <a href="#webverificationavailableinterface">\*</a></p></td><td><p>Deletes the attachment file with the given name.</p><p><strong>Note: </strong> When deleting an element, its existence is not checked. Thus the method succeeds even if the element being deleted is not in the collection.</p></td></tr><tr><td><p>Get( name : string) : <a href="/flexi-capture/appendix/scripts/iattachment">IUserAttachment</a> <a href="#webverificationavailableinterface">\*</a></p></td><td><p>Accesses the attachment file with the given name</p></td></tr><tr><td><p>Has( name : string) : bool <a href="#webverificationavailableinterface">\*</a></p></td><td><p>Checks whether the attachment file with the specified name exists</p></td></tr></tbody></table>

## Properties

| **Name** | **Type**                                                  | **Access** | **Description**                                        |
| -------- | --------------------------------------------------------- | ---------- | ------------------------------------------------------ |
| IsEmpty  | bool                                                      | Read-only  | Checks whether the array contains any attachment files |
| Names    | [IVariantArray](/flexi-capture/appendix/scripts/ivariant) | Read-only  | The array with the names of attachment files           |
