Here is code....

Spinner s = (Spinner) findViewById(R.id.spinner);
       ArrayAdapter adapter = ArrayAdapter.createFromResource(
               this, R.array.planets,
android.R.layout.simple_spinner_item);
       adapter.setDropDownViewResource
(android.R.layout.simple_spinner_dropdown_item);
       s.setAdapter(adapter);

<string-array name="planets">
       <item>first</item>
       <item>second</item>
       <item>third</item>
   </string-array>

I want to use id of array to call other class.....
something like this  swith(i) :
case 0: Intent i = new Intent(this,xxx.class);
           startActivity(i);

case 1: xxxxxxxxxxxxxxxxxxxxxxxxx
how to write exactly. Can anyone help?
Thank you.
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to