I needed to get all the answers that are inside boolean respostas1
and play inside another variable so I can send it to the MySQL database.
The way I did it, it turned me all false.
For example, I have 4 questions, it should bring me: true, false, true and false ...
and is returning false false false.
Why is it returning false and how to solve it?
for (int x=0; x<respostas2.length; x++){
for (final String a : ids){
idPERGUNTAS = a;
}
Log.i("ID da Perguntas", "IDS das Perguntas: "+idPERGUNTAS);
//parametrosPost2.add(new BasicNameValuePair("ids", idPERGUNTAS));
for (String IDPaciente : idPacientes){
for (int i=0; i < respostas2.length; i++){
idPACIENTES = IDPaciente;
}
}
Log.i("ID do Paciente", "IDS dos Pacientes: "+idPACIENTES);
//parametrosPost2.add(new BasicNameValuePair("idNome", idPACIENTES));
for(boolean respostas1 : respostas2){
RESPOSTAS = respostas1;
}
Log.i("Resposta", "Respostas: "+RESPOSTAS);
//parametrosPost2.add(new BasicNameValuePair("respostas", String.valueOf(RESPOSTAS)));
I have 3 values that I would like to send to the database, so I understood, so that I could send all of them ... pq are several answers ... If I put the answer inside the for, it will return all of them to me so that it will triple ...