Hi,

     I'm trying to write an application which will install the apk from a
specified location. The code I've added is

    public void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);

        File apkFile = new File("/data/install_flashplayer.apk");
        Intent intent = new Intent(Intent.ACTION_VIEW);
        intent.setDataAndType(Uri.fromFile(apkFile),
"application/vnd.android.package-archive");
        int reqCode = 0;
        startActivityForResult(intent,reqCode);
        Log.v("REsult","reqCode = "+reqCode);

    }

    This is installing the install_flashplayer.apk from the location /data.
The problem i'm facing is that after the package is installed, it shows a
messagebox with the button "Done". I'm expecting the behaviour of pressing
Done button should close the application itself rather than only closing the
messagebox. Right now, It closes the message box and package installer and
shows my application.

    Can anyone help me how to get notified that "Done" button is pressed and
how to close the application once it is clicked?

Thanks,
Maha

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

Reply via email to