Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- package com.helloworld;
- import android.app.Activity;
- import android.app.AlertDialog;
- import android.os.Bundle;
- import android.content.DialogInterface;
- public class minverden extends Activity {
- public void onCreate(Bundle savedInstanceState) {
- super.onCreate(savedInstanceState);
- AlertDialog alertDialog = new AlertDialog.Builder(this).create();
- alertDialog.setTitle("Reset...");
- alertDialog.setMessage("Are you sure?");
- alertDialog.setButton("OK", new DialogInterface.OnClickListener() {
- public void onClick(DialogInterface dialog, int which) {
- // here you can add functions
- }
- });
- alertDialog.setIcon(R.drawable.icon);
- alertDialog.show();
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement