Worksheet - ListObject
| Event | Description |
| BeforeAddDataBoundRow | Occurs when a user attempts to add a new row. This event is not raised when new rows are added programmatically. Useful when validating the data. |
| BeforeDoubleClick | Occurs when the ListObject is double clicked |
| BeforeRightClick | Occurs when the ListObject is right clicked |
| BindingContextChanged | Occurs when the binding of the ListObject changes |
| Change | Occurs when the contents of the ListObject are changed by a user or programmatically. The event is not raised when calculations cause the change |
| DataBindingFailure | Occurs when the binding of the ListObject fails. This occurs when you try and add a second ListObject to a worksheet. |
| DataMemberChanged | Occurs when the DataMember property is changed by a user or programmatically. |
| DataSourceChanged | Occurs when the DataSource property is changed by a user or programmatically. |
| Deselected | Occurs when the selection is moved outside the ListObject. |
| ErrorAddDataBoundRow | Occurs when an error occurs when attempting to add a new row, (eg violation, entering text in a numeric column) |
| OriginalDataRestored | Occurs when a changed value is restored to its original value as a consequence of an error occurring. |
| Disposed | Occurs when the ListObject is disposed of. Typically raised by garbage collection. |
| Selected | Occurs when the ListObject is selected |
| SelectedIndexChanged | Occurs when the selected index changes. This is the currently selected item in the ListObject. |
| SelectionChange | Occurs when the selection within the ListObject changes. |
This list is slightly different to the VBA Events
You can create ListObjects dynamically
Microsoft.Office.Tools.Excel.ListObject AddListObject(
Microsoft.Office.Interop.Excel.Range range,
string name)
Public Function AddListObject( _
ByVal range As Microsoft.Office.Interop.Excel.Range, _
ByVal name As String) As _
Microsoft.Office.Tools.Excel.ListObject
Excel.Worksheet vstosheet;
Microsoft.Office.Tools.Excel.ListObject listobject;
vstosheet = ActiveWorkbook.Sheets(2).GetVSTOObject
listobject = vstosheet.Controls.AddListObject(Range("A1","B10"),
new System.Guid(---).ToString())
© 2026 Better Solutions Limited. All Rights Reserved. © 2026 Better Solutions Limited TopPrevNext