Highlights
All Snippets
Top 100 Snippets
Librarians
gbCodeLib

By Language
VB6
JavaScript
Perl
HTML
SQL
Java
DOS

GBIC >> Source Code >> Visual Basic >> Snippet

Optionbutton - determine which is selected


Selected = Option (0).value * 0 + Option (1).value * 1 + Option (2).value * 2

'Or

For i = 0 To n
  Selected = Option (i).value * i
Next i