Reputation: 37
I am developing an app for a limited number of users (10 users) in Android. When the app is installed on the 11th device, it should not be installed. How can I do that in Android?
Upvotes: 2
Views: 60
Reputation: 5626
I think the easiest way to do this is by uploading your apk to a server then do the following:
This should prevent unauthorized users from downloading your app.
This will also help you avoid all the checks you will have to do to make sure 10 people have installed your app - since you cannot really avoid an installation.
I hope this gives you an idea.
Upvotes: 1
Reputation: 1847
You cannot prevent the installation ofcourse. But what you can do to handle this problem is that as the app is installed and started, hit a webservice made by you to check if there are more than 10 devices who have already installed this app, if the answer is yes, do not let the user go ahead but if 10 installations havnt been done, do an increment on your server and let the user pass by this step and use the App.
EDIT
As suggested by Saty, A registration process can also be useful in this case.
Upvotes: 0