FederalProgrammer
Programmer
I am trying to add a bunch of objects to my Listbox using an arraylist using the follwoing 2 funx:
My problem is that me._list always contains a single object!!! what's going on with this thing?
---------------
Code:
Private Sub Page_Load(ByVal s As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
'If (Not Me.IsPostBack) Then
Me._list = New ArrayList
Me.ListBox1.DataSource = Me._list
Me.ListBox1.DataBind()
'End If
End Sub
Code:
Private Sub btnAddBandMember_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnAddBandMember.Click
Dim newObject As New SomeObject()
Me._list.Add(newObject)
Me.ListBox1.DataBind()
End Sub
My problem is that me._list always contains a single object!!! what's going on with this thing?
---------------