Hi all,
today I'm experimenting with the XUI Views lib (1.87) and received the following error:
java.lang.RuntimeException: java.lang.RuntimeException: java.lang.Exception: Sub xcbcateg_selectedindexchanged was not found.
I don't need to track each index change event so I don't add what the error clearly indicates. Is it a "bug" (no check in the lib whether the method exist before calling it), is it a requisite (having that sub in my code) or whatever?
This is not normal behaviour, if we had to do this for every unused event our code would be crawling with unfilled subs.
Sounds like a bug to me, and definitely undesirable.
[For newbies - replace the RaiseEvent routine with:
B4X:
Private Sub RaiseEvent
If SubExists(mCallBack, mEventName & "_SelectedIndexChanged") Then
CallSub2(mCallBack, mEventName & "_SelectedIndexChanged", getSelectedIndex)
End If
End Sub