LucaMs Expert Licensed User Longtime User Nov 7, 2014 #1 I have tried: B4X: Sub getList As List Return mapX.Keys End Sub but Keys are defined as IterableList and can not be cast to List
I have tried: B4X: Sub getList As List Return mapX.Keys End Sub but Keys are defined as IterableList and can not be cast to List
Erel B4X founder Staff member Licensed User Longtime User Nov 7, 2014 #2 You can create a sub that goes over the items and adds them to a list.
LucaMs Expert Licensed User Longtime User Nov 7, 2014 #3 Erel said: You can create a sub that goes over the items and adds them to a list. Click to expand... Like this: B4X: Public Sub getFieldsNames As List Dim lst As List : lst.Initialize For Each K As String In mMap.Keys lst.Add(K) Next Return lst End Sub (Sorry, Erel, I knew it )
Erel said: You can create a sub that goes over the items and adds them to a list. Click to expand... Like this: B4X: Public Sub getFieldsNames As List Dim lst As List : lst.Initialize For Each K As String In mMap.Keys lst.Add(K) Next Return lst End Sub (Sorry, Erel, I knew it )