title: Android Spinner getting selectedItem Value?
body: <p>I have setup Spinner with the layout below, and I wanted to get the value of the item selected, not the displayed text.  Where does one pull out the value?   Also will this work for pulling out values the layout below?  Or do I need some other way to setup (value, displayText) pair? So I guess I need to know how to set it up so it has a value and also how in onItemSelected I would pull the value?  </p>
  
  <pre><code>&lt;?xml version="1.0" encoding="utf-8"?&gt;
  &lt;LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
  android:orientation="vertical" android:layout_width="fill_parent"
  android:layout_height="fill_parent" android:paddingLeft="12dip"&gt; 
  &lt;Spinner
  android:id="@+id/viewSpin"
  android:layout_width="fill_parent"
  android:layout_height="wrap_content"   
  android:entries="@array/some_values" 
  android:prompt="@array/some_names"/&gt;
  &lt;/LinearLayout&gt;
  </code></pre>