~~Title: OnCloseTab ~~
The **OnCloseTab** event can be implemented by a [[:scripting:script_add-ins|script add-in]] to receive notification when a tab is closed in a Lister.
$$ (#)**Method Name:**
$$ OnCloseTab
$$ (#)**Argument Type:**
$$ **[[..:scripting_objects:closetabdata|CloseTabData]]**
$$ (#)**Return Type:**
$$ //bool//
$$ (#)**Description:**
$$ The **CloseTabData.tab** property identifies the tab that is closing. You can return **True** from this event to prevent the tab from closing, or **False** (which is the default) to allow it to close.
Note that when a Lister closes this event is **not** triggered for each of its tabs - the **[[oncloselister|OnCloseLister]]** event provides notification when a Lister closes, and all the tabs in that Lister as discoverable through the **CloseListerData.lister.tabs** property.