But how will the users install this application that checks for the other application's apk file?
13 декабря 2011 г. 22:13 пользователь ndnfan <[email protected]> написал: > Thanks for the replies. I like the idea of using email to distribute > the app since it's a simple interface that user's already know how to > navigate. I also found a way to do it programmaticly. The code below > will open the file at location APPNAME and, if successfully opened, > will present the user a dialog box requesting permission to reinstall > the application. > > // Attempt to open the file > File app = new File(APPNAME); > > if (app.exists()) { > Intent apkIntent = new Intent(); > > apkIntent.setAction(android.content.Intent.ACTION_VIEW); > apkIntent.setDataAndType(Uri.fromFile(app), > > "application/vnd.android.package-archive"); > startActivity(apkIntent); > } > > So I could create an application that checks for a specific filename > when the USB stick is inserted. > > -- > You received this message because you are subscribed to the Google > Groups "Android Developers" group. > To post to this group, send email to [email protected] > To unsubscribe from this group, send email to > [email protected] > For more options, visit this group at > http://groups.google.com/group/android-developers?hl=en -- You received this message because you are subscribed to the Google Groups "Android Developers" group. To post to this group, send email to [email protected] To unsubscribe from this group, send email to [email protected] For more options, visit this group at http://groups.google.com/group/android-developers?hl=en

