How to create collection object with vb.net

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

hi i know to create collection of object with vb
but dont know how to do that thing using vb.net
thanks
 
* "=?Utf-8?B?S2hhbg==?= said:
hi i know to create collection of object with vb
but dont know how to do that thing using vb.net

\\\
Dim c As New Collection() ' or ArrayList.
c.Add(...)
///
 
sorry it was no
let me explain a bi

i have a class suppose student and i want to store different information about student and want to create student collection so if i add student i have to just call add function and also i dont have to specify the length of arra
 
i have a class suppose student and i want to store different information about student and want to create student collection so if i add student i have to just call add function and also i dont have to specify the length of array

You can use an ArrayList for this.

Dim alStudents As New ArrayList

Dim oStudent As New StudentClass

alStudents.Add(oStudent)
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top