title: Application should run everyday at 10 in the morning
body: <p>I am creating an app with will run everyday morning onetime. I am getting RunTimeException error so unable to understand, if the app is really running or not? </p>
  
  <p>error is: <strong>Unable to instantiate receiver</strong>. even if I declared receiver in my manifest</p>
  
  <p><strong>MainSchedulerClass.java</strong></p>
  
  <pre><code>package com.example.displayscheduler;
  
  import java.util.Calendar;
  import java.util.TimeZone;
  
  import android.app.Activity;
  import android.app.AlarmManager;
  import android.app.PendingIntent;
  import android.content.Context;
  import android.content.Intent;
  import android.os.Bundle;
  import android.widget.Toast;
  
  public class MyScheduler extends Activity {
  
      @Override
      protected void onCreate(Bundle savedInstanceState) {
          super.onCreate(savedInstanceState);
          setContentView(R.layout.schedule);
  
          setRecurringAlarm(this);
      }
  
      private void setRecurringAlarm(Context context) {
  
          Calendar updateTime = Calendar.getInstance();
          updateTime.setTimeZone(TimeZone.getTimeZone("GMT+5:00"));
          updateTime.set(Calendar.HOUR_OF_DAY, 10);
          updateTime.set(Calendar.MINUTE, 00);
  
          Intent intent = new Intent(context, Tasks.class);
          PendingIntent recurringDownload = PendingIntent.getBroadcast(context,
                  0, intent, PendingIntent.FLAG_CANCEL_CURRENT);
          AlarmManager alarms = (AlarmManager) this.getSystemService(
                  Context.ALARM_SERVICE);
          alarms.setInexactRepeating(AlarmManager.RTC_WAKEUP,
                  updateTime.getTimeInMillis(),
                  AlarmManager.INTERVAL_DAY, recurringDownload);
      }
  }
  </code></pre>
  
  <p><strong>Tasks.java</strong></p>
  
  <pre><code>package com.example.displayscheduler;
  
  import android.content.BroadcastReceiver;
  import android.content.Context;
  import android.content.Intent;
  import android.util.Log;
  import android.widget.Toast;
  
  public class Tasks extends BroadcastReceiver {
  
      final public static String ONE_TIME = "onetime";
  
      @Override
      public void onReceive(Context context, Intent intent) {
          Log.i(ONE_TIME, "Executed Tasks.Java File");
          //Some task here for every morning
           Toast.makeText(context, "Start Displaying Pictures", Toast.LENGTH_LONG).show();
  
              }
  }
  </code></pre>
  
  <p><strong>manifest</strong></p>
  
  <pre><code>&lt;?xml version="1.0" encoding="utf-8"?&gt;
  &lt;manifest xmlns:android="http://schemas.android.com/apk/res/android"
      package="com.example.displayscheduler"
      android:versionCode="1"
      android:versionName="1.0" &gt;
  
      &lt;uses-sdk
          android:minSdkVersion="14"
          android:targetSdkVersion="21" /&gt;
  
      &lt;uses-permission android:name="android.permission.WAKE_LOCK" /&gt;
      &lt;uses-permission android:name="android.permission.RECEIVE_BOOT_COMPLETED" /&gt;
      &lt;uses-permission android:name="android.permission.VIBRATE"/&gt;
  
      &lt;application
          android:allowBackup="true"
          android:icon="@drawable/ic_launcher"
          android:label="@string/app_name"
          android:theme="@style/AppTheme" &gt;
          &lt;activity
              android:name=".MyScheduler"
              android:label="@string/app_name" &gt;
              &lt;intent-filter&gt;
                  &lt;action android:name="android.intent.action.MAIN" /&gt;
  
                  &lt;category android:name="android.intent.category.LAUNCHER" /&gt;
              &lt;/intent-filter&gt;
          &lt;/activity&gt;
          &lt;activity
              android:name=".Tasks"
              android:enabled="true"
              android:label="@string/app_name" &gt;
          &lt;/activity&gt;
  
          &lt;receiver android:name="com.example.displayscheduler.MyScheduler" &gt;
          &lt;/receiver&gt;
      &lt;/application&gt;
  
  &lt;/manifest&gt;
  </code></pre>