ya, thank you for that

On Sun, Mar 14, 2010 at 12:18 PM, TreKing <treking...@gmail.com> wrote:

> On Sat, Mar 13, 2010 at 11:07 PM, murali raju <manutd...@gmail.com> wrote:
>
>> use spinner.setOnItemClickListener(new OnItemClickListener()
>>
>
> No, this won't work, read the documentation: "A spinner does not support
> item click events."
> You want setOnItemSelectedListener().
>
> On Sat, Mar 13, 2010 at 11:51 PM, Nitesh Mehta <nite...@gmail.com> wrote:
>
>> Well i already know how to get the item and which index. My problem is
>> that the index is same irrespective of what was selected in spinner 1. How
>> do i know whether spinner 1 was selected or spinner 2?
>
>
> Read the documentation:
>
> http://developer.android.com/intl/de/reference/android/widget/AdapterView.OnItemSelectedListener.html#onItemSelected(android.widget.AdapterView<?>,
> android.view.View, int, 
> long)<http://developer.android.com/intl/de/reference/android/widget/AdapterView.OnItemSelectedListener.html#onItemSelected(android.widget.AdapterView%3C?%3E,+android.view.View,+int,+long)>
>
> The first parameter is the AdapterView that triggered the listener, in your
> case this would be the Spinner.
> Or you could also set a different listener on each spinner ......
>
>
> -------------------------------------------------------------------------------------------------
> TreKing - Chicago transit tracking app for Android-powered devices
> http://sites.google.com/site/rezmobileapps/treking
>
> --
> You received this message because you are subscribed to the Google
> Groups "Android Developers" group.
> To post to this group, send email to android-developers@googlegroups.com
> To unsubscribe from this group, send email to
> android-developers+unsubscr...@googlegroups.com<android-developers%2bunsubscr...@googlegroups.com>
> For more options, visit this group at
> http://groups.google.com/group/android-developers?hl=en
>

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

Reply via email to