Basically I'm developing a social networking app and wanted to know, how I could give possible notifications to the users who have downloaded my app to open the app and use it. It could be on some time period too. But I want to know even when my app isn't running in the background, then how can I give notification to the user to open it and use it?
Asked
Active
Viewed 473 times
2
-
just a thought but maybe you can have your app write to some file in storage whenever it is opened. Then, you have a background service (which runs independent of the app), check this file and send a notif if the last time the app wrote to the file has exceeded some defined time period – a2345sooted May 09 '15 at 12:19
-
I'd focus on making an app people want to use all the time instead of finding ways to annoy them when they don't. – Jeffrey Bosboom May 10 '15 at 03:06
2 Answers
3
For reminding you can use alarm manger. while exiting app sets alarm manager after 3 days.
If user opens app within 3 days then cancel alarm and while exiting app again set alarm manager

N J
- 27,217
- 13
- 76
- 96
-
Thanks for the answer but I want to know what if the user just installed the app and didn't open it even once? Will the notification come then? – user2851212 May 09 '15 at 12:20
-
1why will a user install an app if he dont want to open it atleast once – Vishwajit Palankar May 09 '15 at 12:23
0
whenever the user opens the app store the devices current date in your machine using SharedPreferences
and keep a service running in the background which will check the systems current date and the date you have stored in your SharedPreferences
and according to your logic when you think it is too much time give the notification
Links SharedPreferences & service

Community
- 1
- 1

Vishwajit Palankar
- 3,033
- 3
- 28
- 48
-
Will the service run even if the app hasn't been opened even once? – user2851212 May 09 '15 at 12:23
-
why will a user install an app if he dont want to open it atleast once – Vishwajit Palankar May 09 '15 at 12:23
-
-
i said that it wont work until the user has opened it once but that is not logical – Vishwajit Palankar May 09 '15 at 12:26