1

im a new user for android development. i need to show the monthly calendar when button click. how to do it.

Calendar cal = Calendar.getInstance();              
Intent intent = new Intent(Intent.ACTION_EDIT);
intent.setType("vnd.android.cursor.item/event");
intent.putExtra("beginTime", cal.getTimeInMillis());
intent.putExtra("allDay", true);
intent.putExtra("rrule", "FREQ=YEARLY");
intent.putExtra("endTime", cal.getTimeInMillis()+60*60*1000);
intent.putExtra("title", "A Test Event from android app");
startActivity(intent);

is their any method avail for monthly calendar

Ram kiran Pachigolla
  • 20,897
  • 15
  • 57
  • 78
shivcena
  • 2,023
  • 8
  • 24
  • 50
  • http://stackoverflow.com/questions/6080307/how-to-display-a-calendar-ui-in-an-android-application . This link contains similar question and has correct answer, too. Hope it helps. – MysticMagicϡ Nov 27 '12 at 07:01
  • still i will not able to find the source code, i try this code is it right,Intent i = new Intent(); ComponentName cn; //Froyo or greater (mind you I just tested this on CM7 and the less than froyo one worked so it depends on the phone...) cn = new ComponentName("com.google.android.calendar", "com.android.calendar.LaunchActivity"); //less than Froyo // cn = new ComponentName("com.google.android.apps.maps","com.google.android.maps.MapsActivity");i.setComponent(cn);startActivity(i); setContentView(R.layout.main); causes activity not found exception – shivcena Nov 27 '12 at 10:35

0 Answers0