Hi,
I am using a Toast inside an IntentService.
To fix the not disappearing toast issue I have used an handler:
private Handler handler = new Handler();
...
handler.post(new Runnable() {
@Override
public void run() {
Toast.makeText(getApplicationContext(), "Network problem",
Toast.LENGTH_SHORT)
.show();
}
});
and it is working properly.
Regards,
Tobia Loschiavo
On Tuesday, March 1, 2011 3:53:48 AM UTC+1, julius wrote:
>
> Hi,
>
> I have an IntentService from which I am showing a Toast using:
>
> Toast.makeText(this, errorMessage.toString(),
> Toast.LENGTH_SHORT).show();
>
> For some reason it's not disappearing. Just wondering if anyone has seen
> this before or knows what I'm doing wrong. I'm sure it's just something I'm
> not thinking of but I'm stumped...
>
> Thanks in advance.
>
> Regards,
> Julius.
>
>
On Tuesday, March 1, 2011 3:53:48 AM UTC+1, julius wrote:
>
> Hi,
>
> I have an IntentService from which I am showing a Toast using:
>
> Toast.makeText(this, errorMessage.toString(),
> Toast.LENGTH_SHORT).show();
>
> For some reason it's not disappearing. Just wondering if anyone has seen
> this before or knows what I'm doing wrong. I'm sure it's just something I'm
> not thinking of but I'm stumped...
>
> Thanks in advance.
>
> Regards,
> Julius.
>
>
On Tuesday, March 1, 2011 3:53:48 AM UTC+1, julius wrote:
>
> Hi,
>
> I have an IntentService from which I am showing a Toast using:
>
> Toast.makeText(this, errorMessage.toString(),
> Toast.LENGTH_SHORT).show();
>
> For some reason it's not disappearing. Just wondering if anyone has seen
> this before or knows what I'm doing wrong. I'm sure it's just something I'm
> not thinking of but I'm stumped...
>
> Thanks in advance.
>
> Regards,
> Julius.
>
>
--
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en