So your you just need to add the missing properties to your class.
Quote:
as i'm filing candidateInfo in my list, which contains, candidate id, name, cell no, age...etc.. in the same list i want to add GroupName
Your class should look something like the follow, not sure what that code snippet you posted is from.
public class CandidateInfo
{
public int CandidateId {get;set;}
public string Name {get;set;}
public string CellNo {get;set;}
public int Age {get;set;}
public string GroupName {Get;set;}
}
Then you'll be able to access/assign values to any properties you add later on while using the CandidateInfo class. Ex:
var candidates = new List<CandidateInfo>();
var c1 = new CandidateInfo();
c1.Name = "Matt";
c1.GroupName = "Group 1";
var c2 = new CandidateInfo();
c1.Name = "Mark"
c1.GroupName = "Group 2";
candidates.Add(c1);
candidates.Add(c2);