I\'ve build a contacts sync adapter. It\'s all working fine but I need one more thing. If for some reason the sync does not complete successfully, I want to show a message l
I think what you want are Toasts
Simple Toast:
Toast.makeText(context, text, duration).show();
text is, as you can imagine, the text you want to be displayed.
duration is either Toast.LENGTH_SHORT or Toast.LENGTH_LONG (depends in how long the Toast sahll be visible)
More complicated approach with picture in the toast: (sync_toast_lo.xml)
And in your code:
LayoutInflater inflater = getLayoutInflater();
View view = inflater.inflate(R.layout.Sync_toast_lo,
(ViewGroup) findViewById(R.id.SynctoastLayout));
Toast toast = new Toast(this);
toast.setView(view);
toast.show();