The below given code is working fine, but not sure whether this is the right way to get the value of the clicked item whenever the user changes the value in the radio group
I could not find any property of ABMRadioGroup to get the text of the Active Item, hence I used the below given method
B4X:
Sub rbgroup_Clicked(Target As String)
Log(Target & " clicked")
Dim cClickedOn As String
Dim rbgroup As ABMRadioGroup = page.Component("rbgroup")
If rbgroup.GetActive() = 0 Then
cClickedOn = "Male"
Else
cClickedOn = "Female"
End If
myToastId = myToastId + 1
page.ShowToast("toast" & myToastId, "toastgreen", "Clicked "&cClickedOn, 5000, False)
page.Refresh
End Sub