View Single Post
 
Old 06-06-2012, 09:30 AM
tinfanide tinfanide is offline Windows 7 64bit Office 2010 32bit
Expert
 
Join Date: Aug 2011
Posts: 312
tinfanide is on a distinguished road
Default

Quote:
Originally Posted by Colin Legg View Post
You can access it via a ListObject object, for example:
Code:
Worksheets("Sheet1").ListObjects("oTable").ListColumns("Header1").Range.Cells(1).Select
You have to be careful with the [ ] because they are also shorthand for the Evaluate method in VBA. This would also potentially work, but (in my opinion) it is confusing and an ugly piece of code best avoided:
Code:
[oTable[[#Headers],[Header1]]].Select
Yeah. Just liked the shortened one. The ListObjects.ListColumns. too long.
Reply With Quote