RadioButtonList

D

Dot Net Daddy

I have a radioButtonList. It is AutoPostBack Enabled. And on every
postBack the selected item stays there. I want on every page_load no
item in the RadioButtonList to be selected. How can I do this?

Thanks in advance.
 
G

Guest

Hello Dot Net Daddy,

To deselct any item in a RadioButtonList, you could do something like this:

for (int i = 0; i < RadioButtonList1.Items.Count; i++)
{
RadioButtonList1.Items.Selected = false;
}

Of course, you would probably want to process the user input beforehand
(otherwise, why ask?).
 
D

Dot Net Daddy

Thank you very much.

Hello Dot Net Daddy,

To deselct any item in a RadioButtonList, you could do something like this:

for (int i = 0; i < RadioButtonList1.Items.Count; i++)
{
RadioButtonList1.Items.Selected = false;
}

Of course, you would probably want to process the user input beforehand
(otherwise, why ask?).
--
enjoy - brians
http://www.limbertech.com


Dot Net Daddy said:
I have a radioButtonList. It is AutoPostBack Enabled. And on every
postBack the selected item stays there. I want on every page_load no
item in the RadioButtonList to be selected. How can I do this?

Thanks in advance.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,968
Messages
2,570,153
Members
46,699
Latest member
AnneRosen

Latest Threads

Top