title: how to fix context cannot be resolved or is not a field?
body: <p>i am trying to enable alarmManager and also my broadcastreceiver through another service everytime i receive an SMS but the problem is, i am getting this error on the third line -<strong>context cannot be resolved or is not a field</strong>. i have already replaced all the <code>this</code> with <code>context</code>. what am i missing?</p>
  
  <pre><code>private void freeze(Context context) {
      // ENABLE MyReceiver SERVICE
              ComponentName receiver = new ComponentName(IncomingSmsDetectorReceiver.context,
                      FreezerReceiver.class);
              PackageManager pm = context.getPackageManager();
              pm.setComponentEnabledSetting(receiver,
                      PackageManager.COMPONENT_ENABLED_STATE_ENABLED,
                      PackageManager.DONT_KILL_APP);
              // --//
              Intent intent = new Intent(context, FreezerReceiver.class);
              PendingIntent sender = PendingIntent.getBroadcast(context, 0, intent,
                      PendingIntent.FLAG_CANCEL_CURRENT);
              AlarmManager am = (AlarmManager) context
                      .getSystemService(Context.ALARM_SERVICE);
              long recurring = (500); // tweak here
              am.setRepeating(AlarmManager.RTC, Calendar.getInstance()
                      .getTimeInMillis(), recurring, sender);
  }
  </code></pre>