mercredi 18 août 2021

I used If statement. If the statement is false then it will show up a toast message, my problem was the toast message shows up either true or false

** I used If statement. If the statement is true then the textview vallue will show then if false it will show up a toast message, my problem was the toast message shows up either true or false.**

 if (entry.getValue()==maxValueInMap && maxValueInMap > minProbabilityThreshold) {
                classitext.setText(entry.getKey());
            } else {
                classitext.setText("  ");
                Toast.makeText(, "Unkown Image", Toast.LENGTH_SHORT).show();
            }

Aucun commentaire:

Enregistrer un commentaire