iOS Question How can I add a value to a dynamically created picker item

davepamn

Active Member
Licensed User
Longtime User
I need to add a Key/Value pair for each element in the data picker.
 
Last edited:

davepamn

Active Member
Licensed User
Longtime User
Can a Data picker have a Key/Value pair?

My Key is different from the display for the data picker.

Are you saying that I will need to create a Map that holds the key and use the description to lookup the Key?

I would rather have the control hold the key for the item
 
Last edited:
Upvote 0

davepamn

Active Member
Licensed User
Longtime User
B4X:
                Dim oKeyValue As AttributedString
                Dim oFont As Font
                oFont=Font.CreateNew(30)
       
                oKeyValue.Initialize(sListText,oFont, Colors.Black)
                oKeyValue.Tag=sListValue

                myList.Add(oKeyValue)

AttributeString work!

On the reverse side, How do I get the tag value for the selected data picker item?
 
Upvote 0
Top