I'm developing an app for android in my company that will be running in a few tablets, if I make some changes I need to re-download and re-install my app in server manually. is there any way to do this automatically? I've search it, and this is what I've got;
protected void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
setContentView(R.layout.activity_main);
Intent intent = new Intent(Intent.ACTION_VIEW ,Uri.parse("http://192.168.xxx.xxx/myApp.apk"));
startActivity(intent);
}
but it only download from my apk link, but it didn't install my apk, and everytime I open my app, It always download from my link, I want to make it only download when there's new app, and automatically install it.
We have a text file on the server containing the current release version (as an int) and the version number (eg 1.1.31)
Once a day the app will check load that data and compare to the current build number then prompt to download if the server version is higher. In your case you'd do the check first before calling the intent.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With