I have a Array.It has for example 10 rows. I need to checka flg. if flag has value false it goes to array number one,if it have flag true it goes go array number 2.I'm trying something like this.
if (lista2[i].FLG_FALHA == true)
{
listaInc[c] = lista2[i];
i++;
c++;
}
else
{
listaAlr[o] = lista2[i];
o++;
i++;
}
This is where i declare the arrays.
List<AcompanhamentoSiltIncDTO> lista2 = new List<AcompanhamentoSiltIncDTO>();
List<AcompanhamentoSiltIncDTO> listaInc = new List<AcompanhamentoSiltIncDTO>();
List<AcompanhamentoSiltIncDTO> listaAlr = new List<AcompanhamentoSiltIncDTO>();
I get this error,it's like the arrays are not initialized.
"{"The index was out of range, it should be non-negative and less than the size of the collection. \ R \ nName parameter: index"}"