请看 AlertDialog.Builder 类。 http://developer.android.com/guide/topics/ui/dialogs.html#AlertDialog 这个链接应该提供了你所需要的所有信息。