Quote Originally Posted by stratos View Post
Thanks for the replies guys. I have used the simpliest soluton. I have just forced a radiobutton to be checked from the beginning.
Also, I haven't thought some things you have mentioned, so I will rewrite some of the code to make the program more friendly to the user.
P.S. @dday9. What can I write to replace the 'GOTO' statement? I have used an EXIT SUB command, since I have made the 'GOTO' skip the code and go to the last line. I think it's the same thing.
What if I would like to go to another line?
Eww! Ick! No!...


try this:
Code:
dim bOKToContinue as Boolean = False
For Each Me.I In Me.Controls
If TypeOf I Is RadioButton Then
  if I.Checked Then 'Or what ever it is for a RB, I'm shooting from the hip here....
    bOKToContinue = True
    Exit For
  end if
Next I

if not bOKToContinue Then
   MsgBox("PICK UP A RADIOBUTTON", MsgBoxStyle.OkOnly, "WARNING!")
end if
-tg