Re: Setting RadioButtonList selection

Tech Tip: Click here to run a free scan for Windows Errors and optimize PC performance



Dan:

Try using the SelectedValue property of the RadioButtonList.

For example:

rblMyRBL.SelectedValue = 2


--
David Lloyd
MCSD .NET
http://LemingtonConsulting.com

This response is supplied "as is" without any representations or warranties.


"dhnriverside" <dan@xxxxxxxxxxxxx> wrote in message
news:77D4C21A-54B8-472C-8C48-59093295DE98@xxxxxxxxxxxxxxxx
Hi guys

I have a radiobuttonlist with 3 listItems, with values 0, 1 and 2
respectively.

My database stores the number, but how do I set the selected on the brl to
correspond with the database.

I tried rblMyRBL.Items.FindByValue(dbfield).Selected = true;

but the selection doesn't change. Any thoughts?

Cheers


Dan


.


Quantcast