# TabStats

The **TabStats** object provides various information and statistics about the current folder displayed in a tab. Note that the [**Tab**](tab) object provides two versions of this object. **Tab.selstats** takes [Checkbox Mode](../../../basic_concepts/selecting_files/selecting_with_the_mouse_and_keyboard/checkbox_mode) into account, and in this mode the values of the "checked" and the "selected" properties will be the same. If the object was retrieved via **Tab.stats** and the file display is in Checkbox Mode, the two sets of properties will be different.

| Property Name      | Return Type                       | Description                                                                                                                                               |
| ------------------ | --------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------- |
| bigimage\_h        | _int_                             | Returns the width in pixels of the largest image in the folder.                                                                                           |
| bigimage\_w        | _int_                             | Returns the height in pixels of the largest image in the folder.                                                                                          |
| bytes              | _object:_[**FileSize**](filesize) | Returns the total number of bytes in the folder as a [**FileSize**](filesize) object.                                                                     |
| checkbox\_mode     | _bool_                            | Returns **True** if the tab is currently in [Checkbox Mode](../../../basic_concepts/selecting_files/selecting_with_the_mouse_and_keyboard/checkbox_mode). |
| checkedbytes       | _object:_[**FileSize**](filesize) | Returns the total number of bytes in checked items as a [**FileSize**](filesize) object.                                                                  |
| checkeddirbytes    | _object:_[**FileSize**](filesize) | Returns the total number of bytes in checked folders as a [**FileSize**](filesize) object.                                                                |
| checkeddirs        | _int_                             | Returns the total number of checked folders.                                                                                                              |
| checkedfilebytes   | _object:_[**FileSize**](filesize) | Returns the total number of bytes in checked files as a [**FileSize**](filesize) object.                                                                  |
| checkedfiles       | _int_                             | Returns the total number of checked files.                                                                                                                |
| checkeditems       | _int_                             | Returns the total number of checked items.                                                                                                                |
| checkedmusiclength | _int_                             | Returns the total length in seconds of all checked music files.                                                                                           |
| dirbytes           | _object:_[**FileSize**](filesize) | Returns the total number of bytes in all folders as a [**FileSize**](filesize) object.                                                                    |
| dirs               | _int_                             | Returns the total number of folders.                                                                                                                      |
| filebytes          | _object:_[**FileSize**](filesize) | Returns the total number of bytes in all files as a [**FileSize**](filesize) object.                                                                      |
| filedate\_max      | _date_                            | Returns the latest (most recent) file date in the folder.                                                                                                 |
| filedate\_min      | _date_                            | Returns the earliest (oldest) file date in the folder.                                                                                                    |
| files              | _int_                             | Returns the total number of files.                                                                                                                        |
| items              | _int_                             | Returns the total number of items.                                                                                                                        |
| largestfile        | _object:_[**FileSize**](filesize) | Returns the size of the largest file in the folder as a [**FileSize**](filesize) object.                                                                  |
| musiclength        | _int_                             | Returns the total length in seconds of all music files.                                                                                                   |
| selbytes           | _object:_[**FileSize**](filesize) | Returns the total number of bytes in all selected items as a [**FileSize**](filesize) object.                                                             |
| seldirbytes        | _object:_[**FileSize**](filesize) | Returns the total number of bytes in all selected folders as a [**FileSize**](filesize) object.                                                           |
| seldirs            | _int_                             | Returns the number of selected folders.                                                                                                                   |
| selfilebytes       | _object:_[**FileSize**](filesize) | Returns the total number of bytes in all selected files as a [**FileSize**](filesize) object.                                                             |
| selfiles           | _int_                             | Returns the number of selected files.                                                                                                                     |
| selitems           | _int_                             | Returns the number of selected items.                                                                                                                     |
| selmusiclength     | _int_                             | Returns the total length in seconds of all selected music files.                                                                                          |

| Method Name | **Arguments** | Return Type | Description                                                                                                                                                                                                                                                                                                                                  |
| ----------- | ------------- | ----------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| Update      | _none_        | _none_      | The first time a script accesses a particular **TabStats** object, a snapshot is taken of the tab state. If the script then makes changes to that tab (e.g. it selects files, creates a new folder, etc), these changes will not be reflected by the object. To re-synchronize the object with the tab, call the **TabStats.Update** method. |
