• 3
name

A PHP Error was encountered

Severity: Notice

Message: Undefined index: userid

Filename: views/question.php

Line Number: 191

Backtrace:

File: /home/prodcxja/public_html/questions/application/views/question.php
Line: 191
Function: _error_handler

File: /home/prodcxja/public_html/questions/application/controllers/Questions.php
Line: 433
Function: view

File: /home/prodcxja/public_html/questions/index.php
Line: 315
Function: require_once

name Punditsdkoslkdosdkoskdo

How can I manage four spinners on Android?

I have four spinners on Android.

The better way to explain the work of the spinners is this site.

On the left side of the browser, there are four dropdown menus and I want the same build implemented on an Android app, but when one spinner changes it's affecting the other!

spSura.setOnItemSelectedListener(new AdapterView.OnItemSelectedListener() 
{
public void onItemSelected(AdapterView<?> parent, View view, int position, long id) 
{
  browse.changeSura();
}
public void onNothingSelected(AdapterView<?> parent) {}

The code above is part of my code and it shows which listener I use.

      • 1
    • You should provide us more snippets of your code related to managing these spinners. With so little information we may only guess what's wrong with your implementation. Also, please fix English because I hardly understood the problem

Your question is not clear for me it's better if you share the full code of the problem. I think you're not able to differentiate between the spinners so add individual id's for each spinner and try to track the change on each of them and give different action as follows

  if(view.getId()){
     case R.id.spinners_1:
      // change spinners 1
         break;
     case case R.id.spinners_2:
       // change spinners 2
          break;
    }
  • 1
Reply Report