Ok, I asked this question and got excellent code example as answer. The code works but I don't understand the meaning of the code. Can someone point the direction for me for further reading in order to understand the code. Here is the code that retrieves the checked radio button in a groupbox:
Dim rButton As RadioButton = GroupBox1.Controls _
.OfType(Of RadioButton)() _
.Where(Function(r) r.Checked = True) _
.FirstOrDefault()
Ok, the parts that I don't understand are .OfType
, .Where
, .FirsrOrDefault
UPDATE:
Thanks guys, those things are LINQ