title: Setting spinners in fragment
body: <p>I am trying to set the values for my spinner from a string Array in one of my fragments in the  <code>onCreateView</code> in my <code>public final class Manual extends Fragment</code>:</p>
  
  <pre><code>@Override
  public View onCreateView(LayoutInflater inflater, ViewGroup container, Bundle savedInstanceState) {
  
      View v = inflater.inflate(R.layout.manual, container, false);
  
      String [] values = 
          {"Time at Residence","Under 6 months","6-12 months","1-2 years","2-4 years","4-8 years","8-15 years","Over 15 years",};
      Spinner spinner = (Spinner) v.findViewById(R.id.spinner1);
      ArrayAdapter&lt;String&gt; LTRadapter = new ArrayAdapter&lt;String&gt;(this.getActivity(), android.R.layout.simple_spinner_item, values);
      LTRadapter.setDropDownViewResource(android.R.layout.simple_dropdown_item_1line);
      spinner.setAdapter(LTRadapter);
  
      return inflater.inflate(R.layout.manual, container, false);
  
  }
  </code></pre>
  
  <p>I get no errors with my code, however it doesn't set the spinner. The spinner remains blank with no values. Any ideas on why my code isn't setting the spinner?</p>