Collection: Elements <DataPlugin>
- Updated2024-09-12
- 1 minute(s) read
(Collections | Element
Collection: Elements <DataPlugin>
Collection of all Element objects. These objects contain information about the currently edited data store. The elements from this collection might be ChannelGroup or Channel types.
| Note If the data store currently processed by the DataFinder contains several channels with the same name, the DataPlugIn only loads the first of those channels with the file loader, for example DataPlugin(CSV). |
The following example transfers the information about channel groups in the FromStore object, into the TDM data model structure:
Sub ReadStore(FromStore) Call FindAndCreateGroups(FromStore.Children) End Sub Sub FindAndCreateGroups(StoreElements) Dim StoreElement Dim TDMGroup For Each StoreElement in StoreElements If StoreElement.IsKindOf(eStoreChannelGroup) Then Set TDMGroup = Root.ChannelGroups.Add(StoreElement.Name) Call TDMGroup.Properties.AddProperties(StoreElement.Properties) Else Call FindAndCreateGroups(StoreElement.Children) End If Next End Sub