asp.net vb ????????????????????????

  • Thread starter Thread starter Jay W
  • Start date Start date
J

Jay W

Guest
why do i get this error message:

'DataSource' is not a member of 'System.Web.UI.WebControls.RadioButton'.

when i have this code


Partial Class Practice_Arraylist
Inherits System.Web.UI.Page

Protected Sub Page_Load(ByVal sender As Object, ByVal e As System.EventArgs) Handles Me.Load

Dim countries As New ArrayList
countries.Add("England")
countries.Add("France")
countries.Add("USA")
countries.Add("Russia")
countries.Add("Italy")

countries.TrimToSize()

countries.Sort()

RadioButton1.DataSource = countries
RadioButton1.DataBind()





End Sub
End Class
 
Shouldnt you be using a radio button list, your trying to bind more than 1 item to a single radio button
 
Back
Top