Click here to Skip to main content
Sign Up to vote bad
good
See more: C#VB.NET
Hi,
I have class 'Student' , I want to create multiple instance of class 'Student' and want to assign instance name as S1,S2,S3..etc(1,2,3 will be id of student , so instance name will be as S+StudentID) at runtime. How can i do this?
 
Thanks.
Posted 18-Dec-12 22:10pm


2 solutions

I would use an array of objects (or a List). Almost the same effect without too much effort.
  Permalink  
got my answer here ,
  Permalink  
Comments
jibesh - 19-Dec-12 6:44am
Yes. thats what CPallini provided as solution. If that helps you can accept his answer.

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

  Print Answers RSS
Your Filters
Interested
Ignored
     
0 Christian Graus 448
1 Ron Beyer 286
2 samadhan_kshirsagar 229
3 OriginalGriff 223
4 Tadit Dash 213
0 Sergey Alexandrovich Kryukov 7,017
1 Prasad_Kulkarni 3,815
2 OriginalGriff 3,557
3 _Amy 3,372
4 CPallini 3,010


Advertise | Privacy | Mobile
Web01 | 2.6.130619.1 | Last Updated 19 Dec 2012
Copyright © CodeProject, 1999-2013
All Rights Reserved. Terms of Use
Layout: fixed | fluid