Senhores, boa tarde!
Estou com dificuldade em solucionar esse caso.
Estou tomando esse erro quando tento escrever uma consulta feita em uma banco SQL.
system.formatexception index zero based must be greater than or equal to zero
Abaixo o codigo.
reader = comando.ExecuteReader();
string escrita = "{0} \t {1} \t {2} \t {3} \t {4} \t {5} \t {6}";
while (reader.Read())
sw.WriteLine(string.Format(escrita, reader["Cliente"].ToString(),
reader["Data"].ToString(), reader["Nome"].ToString(), reader["DPTO"].ToString(), reader["Status"].ToString(), reader["Atendido
por"].ToString()));