المساعد الشخصي الرقمي

مشاهدة النسخة كاملة : convert part of a list to an array



C# Programming
06-04-2012, 12:01 AM
Hi;
I want to convert a list to an array but just part of it,because my array is smaller than the list.

int[] copyselection = (int[])selec.ToArray(typeof(int[]));
I want to limit the array elements for example ,I want to copy just 100 elements of it;

Thank you all in advance