switch(string) case does not support in android
<p>i have found a problem when i use switch case in android app...the code is below::
 public void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);</p>

<pre><code>    setContentView(R.layout.main);
    this.fillSpinnerItems();

}
public void fillSpinnerItems()
{

    Spinner spin=(Spinner)findViewById(R.id.spinner1);
    ArrayAdapter&lt;CharSequence&gt; adptr=ArrayAdapter.createFromResource(this, R.array.sign_array, android.R.layout.simple_spinner_item);
    adptr.setDropDownViewResource(android.R.layout.simple_spinner_dropdown_item);
    spin.setAdapter(adptr);
    //spin.setOnItemSelectedListener(new MyOnItemSelectedListener());

}
public void Select(View view)
{


    TextView txt1=(TextView)findViewById(R.id.editText1);
    TextView txt2=(TextView)findViewById(R.id.editText2);
    Spinner spin1=(Spinner)findViewById(R.id.spinner1);
    String spin_value= spin1.getItemAtPosition(spin1.getSelectedItemPosition()).toString();

    switch(spin_value)
    {
    case 1:
    {
    }break;
    }
</code></pre>

<p>The error generated in switch(spin_value)...i.e Cannot switch on a value of type String for source level below 1.7. Only convertible int values or enum constants are permitted</p>
