Hi,
I have a RadioButtonList but am having issues obtaining the selectedvalue.
I have the following:
Now this works fine and I can see in the source that is generated that the correct values are there aswell as the text.
However something doesnt seem right when using the SelectedValue. quite simply when i select a radio button and want to use it i get nothing output.
see here (code from a submit button's Click event):
This outputs nothing where there should be a number coming from FaqCat.
any Idea why this is?
I have a RadioButtonList but am having issues obtaining the selectedvalue.
I have the following:
VB.NET:
DataTable = FaqCatAdapter.GetFaqCat
RBLFaqCat.DataSource = DataTable
RBLFaqCat.DataTextField = "Description"
RBLFaqCat.DataValueField = "WFaqCatId"
RBLFaqCat.DataBind()
Now this works fine and I can see in the source that is generated that the correct values are there aswell as the text.
However something doesnt seem right when using the SelectedValue. quite simply when i select a radio button and want to use it i get nothing output.
see here (code from a submit button's Click event):
VB.NET:
Dim FaqCat As String = RBLFaqCat.SelectedValue
...
Response.Write("<br />FaqCat = " & FaqCat)
This outputs nothing where there should be a number coming from FaqCat.
any Idea why this is?