In first file I have this code which works properly.

for (i = 0…)

{

pivot[i] = …; // calculate values of pivot[]

.

}

.

Plot(pivot[i],"",colorTurquoise,styleDashed,zorder=-5); // plot pivot[] data to make sure it is right

StaticVarSet(“pivotCount”,i); // number of elements in pivot[]

StaticVarSet(“pivots”,pivot); // store pivot[]

…

All the data is plotted properly. If I take the code below and put it in the above file everything works. StaticVarGet() gets the data and plots it properly. But I put the below code in a different AFL file and run then pivot[] is empty.

.

.

pivotCount = StaticVarGet(“pivotCount”);

pivot = StaticVarGet(“pivots”);

Plot(pivot[0],"",colorTurquoise,styleDashed,zorder=-5);

In the second AFL file the pivotCount is correct but pivot[] is empty. What am I doing wrong? Is it possible to send array variables via StaticVar? Thanks.