I'm trying out Alexander Stolte's AS Settings library for building preference pages (in my first B4XPages project).
I've added the ASSegmentedTab extension and it works well in the UI, but I can't figure out how to set its value in code, and haven't found an example on the forum.
In the B4XPage_Created event, I create the segmented tab:
...but that didn't do anything, so I went back to the sample code and saw that I needed to drill down to the actual view and set its value, but tried this with no luck:
B4X:
prefs.MainPage.GetProperty("player1Name").View.As(B4XView).Text = settingsMap.Get("player1Name") 'this works
prefs.MainPage.GetProperty("scoreToEnd").View.As(ASSegmentedTab).Index = settingsMap.Get("scoreToEnd") 'this doesn't work