Toast Message in Android

android, duration, toast

Solution

This is quite simple. Just call the cancel method on your ToastMessage as soon as you don't want to show the ToastMessage anymore. Refer Toast cancel()

Problem

Friends, In my application Toast message is Displayed in Activity say UserActivity.class.. That activity includes a button, in which it will Redirect to next Activity in OnClick of button.. What i want is that my Toast Message should display in UserActivity until user taps Button, if user Taps the button my toast message has to be Disappear and Next activity will appear.. Is it possible to do like this, if so how its possible? Thanks Venkatesh.

Original source