Excel Tables | VBA Code
If you work with structured data in Excel, then you likely use Excel tables (known as ListObjects in VBA). This section contains various code snippets that we use here at Matrix9 to make our life easier when dealing with these tables in our code.
For ease, we refer to such Excel tables as XLTs, and all our VBA sub and function names begin with XLT to make it clear what they are used for.
XLT Get Column Number
Used to get the column number of a column in an Excel table, based on the column header’s name
XLT Get Table
When working with Excel tables in VBA, this simple code to gets an Excel table in a workbook and sets it as a variable, without needing to reference sheet names.
Got any questions?
Feel free to offer any thoughts in the comments section for each page. Or get in contact with us direct if you’d prefer