Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Spinner change event problem #81

Open
KrazyTech opened this issue Jul 25, 2017 · 1 comment
Open

Spinner change event problem #81

KrazyTech opened this issue Jul 25, 2017 · 1 comment

Comments

@KrazyTech
Copy link

I didn't get how to implement the spinner change event in mainActivity.java. I'am going to load list in second spinner the on the select of first spinner.

@gpt3ch
Copy link

gpt3ch commented Sep 17, 2017

use this code to get the item selected and position:

spinner1.setOnItemClickListener(new AdapterView.OnItemClickListener() {
@OverRide
public void onItemClick(AdapterView<?> parent, View view, int position, long id) {
Log.d(TAG," selected spinner "+ position);
//load list here as position will tell u what item u have picked
}
});

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants