Users Pricing

forum

Home Forums How do I get the value of the radio button? – MindStick

How do I get the value of the radio button?

Anonymous User 2531 17 Dec 2013

Here are my options (names) for the radio button:

4

2

1

0.5

0.25

I tried using this but it's giving me an error:

multiplier = Convert.ToDouble(radioButton1.SelectedItem.ToString());

Error Message:

'System.Windows.Forms.RadioButton' does not contain a definition for 'SelectedItem' and no extension method 'SelectedItem' accepting a first argument of type 'System.Windows.Forms.RadioButton' could be found (are you missing a using directive or an assembly reference?)

How do I set the value of the multiplier based on what the user set in the radio button?


1 Answers

Markdown for AI

A clean, structured version of this page for AI assistants and LLMs.

Open .md