You already did it for static arrays
dirData[] arrdirData;
Now just set the initial size you want lets make it 50
arrdirData = new dirData[50];
Or if you want it in one line
dirData[] arrdirData = new dirdata[50];
However in C# there you can create dynamic arrays using the generic list class
List<dirdata> arrdirData = new List <dirdata>();
You just the use aardirData.Add to add etc. You can look at the generic list
functions like add, delete, count, replace etc. You will need to include the
generic list header at the top of your file.