Add new item in existing array in c#.net


Question

How to add new item in existing string array in C#.net?

I need to preserve the existing data.

1
122
9/18/2018 12:13:53 AM

I would use a List if you need a dynamically sized array:

List<string> ls = new List<string>();
ls.Add("Hello");
116
10/30/2008 7:04:15 AM

Licensed under: CC-BY-SA with attribution
Not affiliated with: Stack Overflow
Icon