Xojo documentation exemple:

Get the caption of the newly selected radio button

Var newCaption As String
newCaption = Me.SelectedRow.Caption

But the compiler says:

Window1.RadioGroup1.SelectionChanged, line 2
Type "DesktopRadioGroup" has no member named "SelectedRow"
newCaption = Me.SelectedRow.Caption

Documentation inconsistency. Go back to the main page for DesktopGroupBox and you’ll see SelectedItem as a method. Things like this are why I recommend that you never copy and paste code – you never learn how it actually works.

For whoever may be updating the documentation, it’s a problem in both sets:
New doc: SelectionChanged Event with bad sample code
New doc: SelectedItem method

Old doc: SelectionChanged Event with bad sample code
Old doc: SelectedItem method

The solution is

newCaption = me.SelectedItem.Caption

The documentation should be updated.

Thanks Tim, I wrote the solution at the same time.

Is there a way to go to the new documentation?

I mean when selecting from contextual menú:
“Help for anthingselected”

The new documentation is slated to launch with 2022r1. There’s some more details about the new documentation site on the Xojo Blog:

Edit: Also, please pick a post and mark it as an answer! It helps folks glancing at the topic list know which threads have been answered.

Edit 2: I’ve also filed a ticket #68155 - DesktopRadioGroup SelectionChanged example documentation