No Syntax problem, its just not copy... I did something wrong?

On form 2

public string[,] arr = new string[170000, 2];
public string[,] newarr = new string[170000, 20];

On form 1

string[,] arr = new string[170000, 2];
string[,] newarr = new string[170000, 20];

On one load of the first form
Form2 form2 = new Form2
Array.Copy(form2.arr, arr, arr.Length);
Array.Copy(form2.newarr, newarr, newarr.Length);
//form1
private void CreateAndCopy2DArray()
{
    string[,] arr1 = new string[170000, 2];
    string[,] arr2 = new string[170000, 20];
    Form2 f2 = new Forms(arr1, arr2);
    f2.Show();
}
//form2:
public Form2(string[,] arr_1, string[,] arr_2)
{
    //use these two variables here
}
Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.