ListObject.SourceType procedure builder

ListObject.SourceType (Excel)

Returns an XlListObjectSourceType value that represents the current source of the list.

xlSrcExternal - External data source (Microsoft SharePoint Foundation site), xlSrcModel - PowerPivot Model, xlSrcQuery - Query, xlSrcRange - Range, xlSrcXml - XML.
Dim xloSourceType As XlListObjectSourceType
xloSourceType = ActiveCell.ListObject.SourceType