Click here to Skip to main content
15,902,189 members
Please Sign up or sign in to vote.
2.00/5 (1 vote)
See more:
Hi,
I have created two jagged arrays ParamValue, LParamValue like below. Inserted values to ParamValue and copied to LParamValue array using Array::CopyTo, Array::ConstrainedCopy functions. For the first time ParamValue values are inserted into LParamValue correctly after that i modified ParamValue values which are effecting LParamValue array even before CopyTo function call.
But i want to copy values only after CopyTo function call. How to do this. Please help me....

My code:

C++
array<array><double>^&gt; ^ParamValue, ^LParamValue;
ParamValue     = gcnew array<array><double>^&gt;(2);
      ParamValue[0]                = gcnew array<double>(2);
      ParamValue[1]                = gcnew array<double>(3);

      LParamValue                  = gcnew array<array><double>^>(2);
      LParamValue[0]               = gcnew array<double>(2);
      LParamValue[1]               = gcnew array<double>(3);

      ParamValue[0][0] = 3;
      ParamValue[1][0] = 5;
      ParamValue->CopyTo(LParamValue, 0);

      ParamValue[0][1] = 4;
      ParamValue[1][1] = 6;
      ParamValue[1][2] = 7;
      ParamValue->CopyTo(LParamValue, 0);
Posted
Updated 2-Apr-13 4:22am
v2
Comments
Member 9958545 5-Apr-13 1:12am    
Can i expect any solution or is it a simple query?

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900