title: Can't import menuinflator
body: <p>I am following a beginners guide to android programming and I cannot get menuinflator to import, I keep getting</p>
  
  <blockquote>
    <p>the import android.view.MenuInflator cannot be resolved</p>
  </blockquote>
  
  <p>Does this mean I need to add a package to eclipse or is my code wrong in some way? I would really like to continue with the tutorial but I cannot get the example working. </p>
  
  <p>the code is below. </p>
  
  <pre><code>package test.menus;
  
  import android.app.Activity;
  import android.os.Bundle;
  import android.view.Menu;
  import android.view.MenuInflator;
  
  
  public class TestMenusActivity extends Activity {
      /** Called when the activity is first created. */
      @Override
      public void onCreate(Bundle savedInstanceState) {
          super.onCreate(savedInstanceState);
          setContentView(R.layout.main);
      }
  
      public boolean onCreateOptionsMenu(Menu menu)
      {
          MenuInflator inflator = getMenuInflator();
          inflator.inflate(R.menu.mainmenu, menu);
          return true;
      }
  }
  </code></pre>