android - How to avoid reminder when adding an event to the calendar -
i add event calendar method:
private void writetocalendar() { intent l_intent = new intent(intent.action_edit); l_intent.settype("vnd.android.cursor.item/event"); l_intent.putextra(events.title, "title"); l_intent.putextra(events.description, ""); // description l_intent.putextra(events.event_location, ""); //eventlocation l_intent.putextra(events.dtstart, system.currenttimemillis()); // begintime l_intent.putextra(events.dtend, system.currenttimemillis() + event_length); // endtime l_intent.putextra(events.all_day, 0); // allday l_intent.putextra(events.status, events.status_confirmed); // eventstatus l_intent.putextra("visibility", 0); // visibility l_intent.putextra("transparency", 1); l_intent.putextra(events.has_alarm, 0); // hasalarms l_intent.putextra(events.allowed_reminders, ""); //allowedreminders try { startactivity(l_intent); } catch (exception e) { toast.maketext(this.getapplicationcontext(), getresources().gettext(r.string.calendar_error), toast.length_long).show(); } }
unfortunately event proposed user added gets automatically alarm (reminder) set on 10 minutes (at least happens on phone). can see tried set "" allowed reminders , set 0 "hasalarms" flag. still, when adding event automatically proposes user set reminder @ 10 minutes. user can delete reminder before saving event, not want, miss reminder default, application reminder not make sense. can explain how avoid this?
thank you.
Comments
Post a Comment