Give notifications on specific time - android

I created an app in which user can add events in calendar and I want to give user reminder about their event at specific time. Date and time is already specified in event. I want to set notifications for each event.
I searched about it on google and found about alarm Manager but I am confused on how milli second parameter works. Like I want set alarm for 7:30 PM but don't know how it can be done.

If a reminder is all you want to create, check this out How to Create a Reminder Notification in Android?
If what you are looking for is a whole app concept or rather a full tutorial on how to do this, please follow this guide -> Android Task Reminder App [Source Code Included]

Related

How does an Android time based app work?

How does an Android alarm app or any other time based notifications app like Calendar, Clock, etc work? More specifically, how does it show up the notifications at exactly the time specified by the user? Does it constantly run in the background and as soon as the required time comes up, does it show the notification? Or does it schedule the notification in Android's kernel before exiting? I am working on an app that needs to give the user notifications at times specifies by him. I am not able to figure out how to do that.
Maybe what you mean is to create an alarm, you can see this example.

Setting up an Alarm system on android

Im developing an app with a feature by which people can set reminders for themselves for various events (like take medicine with dosage amount). The user should be able to
1) Set a time for the reminder
2) Set a date for the reminder and choose between recurring/ non-recurring
3) When the alarm gets triggered, a notification should be built for the user
4) Alarm should have a snooze option as well
I know how to use notification builder to add a notification with a pending intent and have read documentation on Alarm Manager but Im still completely lost with this task. Could someone please give me some guidance or help?
It seems that the following will supply sufficient documentation on interfacing with alarms in the android SDK.
https://developer.android.com/training/scheduling/alarms.html

How to start a notification at a specified time every day?

I am a new developer and don't know much about android programming. I am trying to make an app that reminds a user to do a particular thing every day at a specific time (like going to gym at 5:30 pm). I am able to get a notification after clicking of a button but i want this to be done by the app i.e. even if the app is not running it will remind me everyday to go the gym at 5:30. How can I get this???
I tried using AlarmManager but it gives my notification at that time only and sets the alarm for the specified time.
Set repeating alarm. on broadcast receiver start your notification

How to set alarm or push notification

I am trying to make a reminder application on Android. I have taken data from the user and saved in a database. How do I trigger an alarm or push notification on user entered date?
To create push notification, you have to register on console API. but I can't post link , because of low reputation and get your own key. Personally I used this tutorial to create and handle push notification.
http://www.androidhive.info/2012/10/android-push-notifications-using-google-cloud-messaging-gcm-php-and-mysql/
but I can't understand why do you need it to alarm user.
To implement alarm after some elapsed time, you can create Service:
http://developer.android.com/reference/android/app/Service.html
There you can create your own alarm or use one of the standard. Sorry, I can't provide code example, because your question is too general.
Insert the information into the Calendar application with the appropriate settings and you will get an alarm when the event occurs.

Android notify the user at a later time

I want to create an application in android in which the user selects a certain day in the future and then, when that day arrives he will get a notification (I know that this can be done through the Calendar or the notes but that doesn't matter in my case).
I have two problems concerting the previous:
a. How should I implement the notification ? I read elsewhere about adding events to the Google Calendar of the user - but that is not standard. Should I implement a service that checks to see if that day has arrived and add the notificatin ?
b. As I wrote, I care about day only, and not time. This generates the following problem for me: When should I notify the user in order to not bother him ? When the application knows only the day of the notification (and not the time) then how can it determine at what time in that day to actually notify the user ? What if the user is asleep ? Is it possible to add a "silent" notification so that the user won't be bothered ?
TIA,
Serafeim
Both problems are solved by a 'status bar notification'
http://developer.android.com/guide/topics/ui/notifiers/notifications.html
You can add a sound to this to alert the user.
If the user is 'asleep' i.e. the phone is on silent I believe the notification won't make a sound.
A notification does not need a time of day as you can 'notify' at the very start of the day and the user will see it when they first check there phone that day, so time is irrelevant.
You will have a service that runs to check the data yes, then start this notification. It may be possible to have an event listener for some given event that would start your service that would then check the date, and if so post your notification!
Here is my tutorial on this:
http://blog.blundellapps.com/notification-for-a-user-chosen-time/
Enjoy!

Categories

Resources