The loop shows makeText (getApplicationContext (), ..., Toast.LENGTH_SHORT) .show ();

for ( int i=0; i<100; i++ ) { ... ... ... makeText(getApplicationContext(), st1, Toast.LENGTH_SHORT).show(); makeText(getApplicationContext(), st2, Toast.LENGTH_SHORT).show(); makeText(getApplicationContext(), st3, Toast.LENGTH_LONG ).show(); } 

But for some reason, the output to the screen after approximately the fifteenth output of makeText (..) suddenly stops. Completely! Without any warnings!

Why is this happening? Not enough memory?

How to solve this problem?

PS Variables st1, st2, st3 - are normally formed and at the time of stopping the output to the screen have normal real (not zero, not empty) string values

  • You created two identical questions. can one delete? Well, yes - give the full code - Alexey Shimansky
  • Dear Alexey! Please reread my questions ... They are different. One is how to stop the output of Toast in a loop ..., the other is suddenly interrupted by the outputs of Toast (the device may not have enough memory). On these two questions, I can not find answers for a long time. (Yes, they are both related to Toast and very important to me) - user_MGU
  • Clear. But the questions described are unclear. Add more information in them. More code that demonstrate the problem. - Alexey Shimansky
  • Good! I will do so, only a little later, in Dan. the moment is busy. ) - user_MGU

0