Notifications
Clear all
VBA & Macros
3
Posts
2
Users
0
Reactions
51
Views
Topic starter
Hi
The subject line says it all, really. Is there VBA code that can return whether a Table was created directly by the user, or is the result of a 'Load To' by Power Query?
EDIT
Many thanks
Ian
Posted : 10/04/2023 3:21 pm
If you want to test if the table is just a range on a worksheet rather than queried from elsewhere, you can use something like:
If Activecell.ListObject.sourcetype = xlsrcrange Then
which returns true if the active cell's table is just a worksheet range.
Posted : 12/04/2023 4:47 am
Topic starter
Hi Velouria
Many thanks!
Ian
Posted : 14/04/2023 4:45 pm