Thanks Saurav
i will try and then tell u
infact i want to take time form user and then set the alarm using alarm
clock app in android
i think it will help
thanks again
On Wed, Mar 24, 2010 at 10:06 PM, Saurav to.saurav.mukher...@gmail.comwrote:
i can help u with the alarm setting, but is that wat u want? or do u want
to use the whole alarm clock application. i dont think that is possible.
here is a snippet that'll show u how to set the alarm, but the pending
intent is wat shud happen when the alarm goes off!
static void schedule(Context context) {
final Intent intent = new Intent(context,
CheckUpdateService.class);
final PendingIntent pending = PendingIntent.getService(context, 0,
intent, 0);
Calendar c = new GregorianCalendar();
c.add(Calendar.DAY_OF_YEAR, 1);
c.set(Calendar.HOUR_OF_DAY, 0);
c.set(Calendar.MINUTE, 0);
c.set(Calendar.SECOND, 0);
c.set(Calendar.MILLISECOND, 0);
final AlarmManager alarm = (AlarmManager)
context.getSystemService(Context.ALARM_SERVICE);
alarm.cancel(pending);
if (DEBUG) {
alarm.setRepeating(AlarmManager.ELAPSED_REALTIME,
SystemClock.elapsedRealtime(),
30 * 1000, pending);
} else {
alarm.setRepeating(AlarmManager.RTC, c.getTimeInMillis(),
UPDATES_CHECK_INTERVAL, pending);
}
}
hope this helps u.
Regards,
Saurav Mukherjee.
On Wed, Mar 24, 2010 at 10:15 PM, Ali Murtaza mralimurt...@gmail.comwrote:
Hi
I want to use the alarm clock applicaiton in my applicaiton plz tell me
how i will use
i am new in android
--
Ali Murtaza
BCSF06M021
Research Assistant
Data Virtulization Ware House
PUCIT, Lahore, Pakistan
ali.murt...@pucit.edu.pk
--
You received this message because you are subscribed to the Google
Groups Android Developers group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.comandroid-developers%2bunsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en
To unsubscribe from this group, send email to android-developers+
unsubscribegooglegroups.com or reply to this email with the words REMOVE
ME as the subject.
--
You received this message because you are subscribed to the Google
Groups Android Developers group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.comandroid-developers%2bunsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en
To unsubscribe from this group, send email to android-developers+
unsubscribegooglegroups.com or reply to this email with the words REMOVE
ME as the subject.
--
Ali Murtaza
BCSF06M021
Research Assistant
Data Virtulization Ware House
PUCIT, Lahore, Pakistan
ali.murt...@pucit.edu.pk
--
You received this message because you are subscribed to the Google
Groups Android Developers group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en
To unsubscribe from this group, send email to
android-developers+unsubscribegooglegroups.com or reply to this email with the
words REMOVE ME as the subject.