i have a structure in a module that i instanciate a table of its type
Public Structure Client
Public _nom As String
Public _prenom As String
Public _age As Integer
End Structure
Module Module1
Public TableauClient(0) As Client
End Module
that i need to populate nd resize every time i hit a certain button
Dim Dimension As Integer = 0
Private Sub Button2_Click(sender As Object, e As EventArgs) Handles Button2.Click
TableauClient(Dimension)._nom = TextBox1.Text.ToString()
TableauClient(Dimension)._prenom = TextBox2.Text.ToString()
TableauClient(Dimension)._age = Val(TextBox3.Text)
Dimension += 1
ReDim TableauClient(Dimension)
End Sub
the problem is i need to fill a listbox with all the elements in the table when i hit another button but i don't even know where to start to do this, tried datasource or add item by item by using concatenations between the three fields but still couldn't get it right