how to install apk file programmatically
Intent intent = new Intent(Intent.ACTION_VIEW);
intent.setDataAndType(Uri.fromFile(new File
(Environment.getExternalStorageDirectory() + "/barcode.apk")), "application/vnd.android.package-archive");
startActivity(intent);
It probably will not work with an android.resource
Uri
. Try copying the APK out to external storage and doing the install from there.