list (List) where the first value has supported repeated

good night, I need to create a list (List) where the first value has supported repeated, for example
1, aaaa
1, bbbb
1, cccc
also to indicate as those values can be read
Who is Participating?
Anurag ThakurConnect With a Mentor Technical ManagerCommented:
i didnt paste the complete working code
i just gave you the prototype of the class which you can use to add in a generic list <T> and then you have use the bottom addition into the list to add to the list items and then later bind that to the dropdown
Can you describe this a little bit more?
Anurag ThakurTechnical ManagerCommented:
you can create a class with two members and add that class in list

class test
   public int i;
   publci text = string.Empty;
   public test()

    public void test(int I, string Text)
        i = I;
        text = Text;

List <test> list = new List<test> ();
list.Add(new text(1, "aaaa");
list.Add(new text(1, "bbbb");
list.Add(new text(1, "cccc");
enrique_aeoAuthor Commented:
Hi, i have this error (view file)
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.