title: Why does this static Receiver not respond to the ACTION_POWER_(DIS)CONNECTED Event?
body: <p>I want a STATIC Broadcast Receiver to get fired, whenever the Phone gets charged or not. In my Manifest.xml, i have written the following Entry:</p>
  
  <pre><code>&lt;receiver
      android:name=".Starter"&gt;
      &lt;intent-filter&gt;
          &lt;action android:name="android.intent.action.ACTION_POWER_CONNECTED" /&gt;
          &lt;action android:name="android.intent.action.ACTION_POWER_DISCONNECTED" /&gt;
      &lt;/intent-filter&gt;
  &lt;/receiver&gt;
  </code></pre>
  
  <p>The Broadcast Receiver itself looks like this:</p>
  
  <pre><code>public class Starter extends BroadcastReceiver {
  
      @Override
      public void onReceive(Context context, Intent intent) {
          Toast.makeText(context, "blablabla", Toast.LENGTH_LONG).show();
      }
  }
  </code></pre>
  
  <p>When I register the Receiver programmatically, everything works fine, but I want the Receiver also to respond, when the Activity is not open, so I have to make a static Receiver.
  Thank you for your help!!!</p>