Arshya Arshya - 1 month ago 7
C# Question

Workbook Events and reading Table Objects

I am working on an Excel workbook add-in where I'm supposed to add a menu item to the ribbon which I already done. I have to enable this menu item when the user clicks on the table object in the worksheet.

Can anyone please tell me what event should I use to achieve this and how to find out of the current cell is part of a table object or not.

Answer

I just used the worksheet.activecell.listobject and checked if the listobject is not null that means the current cell is a part of a table

Comments