J
John Salerno
Here's what I have:
while (readSwitches.Peek() != -1)
{
int i;
string row = readSwitches.ReadLine();
for (int i = 0; i < 32; i++)
{
string[] switches;
switches += row.Split('|');
}
for (int z = 0; z < 8; z++)
{
i = 0;
for (int x = 0; x < 2; x++)
{
for (int y = 0; y < 10; y++)
panelOne[x, y, z] = switches[i++];
}
}
}
Now, the problem here is that each time the while loop runs, it is still
using panelOne in the for loop. I need to change this to panelTwo,
Three, and Four each time the while loop iterates. Should this stuff be
placed out of the loop? Even still, how do I get it to use a different
'panel' array each time?
while (readSwitches.Peek() != -1)
{
int i;
string row = readSwitches.ReadLine();
for (int i = 0; i < 32; i++)
{
string[] switches;
switches += row.Split('|');
}
for (int z = 0; z < 8; z++)
{
i = 0;
for (int x = 0; x < 2; x++)
{
for (int y = 0; y < 10; y++)
panelOne[x, y, z] = switches[i++];
}
}
}
Now, the problem here is that each time the while loop runs, it is still
using panelOne in the for loop. I need to change this to panelTwo,
Three, and Four each time the while loop iterates. Should this stuff be
placed out of the loop? Even still, how do I get it to use a different
'panel' array each time?