title: SharedPreferences Not Working as I would expect
body: <p>I am running into an issue with Shared preferences.  It isn't working as I expected.  Upon login of my application I store an id (google id) in the shared preferences.  On a subsequent activity (about 3 activities later) I attempt to retrieve the id but it is null.  In case it is important, I am attempting to retreive the shared preferences in a onClickListener (from a button).  I am not sure what I am doing wrong.  Any help would be appreciated.</p>
  
  <p>How I am setting it:</p>
  
  <pre><code>    public void setLoginPreferences(String id){
  
      SharedPreferences.Editor editor = getPreferences(MODE_PRIVATE).edit();
      editor.putString(Constants.ID_KEY_NAME, id);
      editor.commit();
  }
  </code></pre>
  
  <p>How I am attempting to get it:</p>
  
  <pre><code>    //setup clickListener for Sumbit Comment
      Button submitButton = (Button) findViewById(R.id.submitComment);
      submitButton.setOnClickListener(new OnClickListener(){
  
          @Override
          public void onClick(View v) {
             //myContext is a global variable set on the onCreate of the activity
              SharedPreferences prefs = myContext.getPreferences(MODE_PRIVATE);
              String userId = prefs.getString(Constants.ID_KEY_NAME, null);   
              SetConcertCommentAsynchWebservice scca = new SetConcertCommentAsynchWebservice(myContext,concertId,userId,Float.toString(soundRatingBar.getRating()),Float.toString(showRatingBar.getRating()),userSubmittedComments.getText().toString()); 
          }});
  }
  </code></pre>