> 
> I am try to display two textviews in single list. But i can not display two adapters at a time. And i try to change values of textview at runtime. It get update value from a dialog box. It's working but not display two adapters at a time.My code is
> 
> 
> 

```
public class MainActivity extends ListActivity {
ArrayList<String> arrayList,a1;
ArrayAdapter<String> arrayAdapter,a2;
RatingBar r1,r2,r3,r4,r5;
TextView t;
Float beh,b,f;
public void onCreate(Bundle savedInstanceState) {
    super.onCreate(savedInstanceState);
    setContentView(R.layout.activity_main);
    ListView listView=(ListView) findViewById(R.id.list);
    String[] items={"Apple","Banana","Coconut","Grape","Peach","Pear"};
    String[] i={"0","0","0","0","0","0"};
    a1=new ArrayList<>(Arrays.asList(i));
    arrayList=new ArrayList<>(Arrays.asList(items));
    arrayAdapter=new ArrayAdapter<String>(this, R.layout.layout, R.id.textView,arrayList);
    a2=new ArrayAdapter<String>(this, R.layout.layout, R.id.textView2,a1);
    listView.setAdapter(a2);
    listView.setAdapter(arrayAdapter);

    listView.setOnItemClickListener(new AdapterView.OnItemClickListener() {
        @Override
        public void onItemClick(AdapterView<?> parent, View view, int position, long id) {
            // Show input box
            showInputBox(a1.get(position),position);
        }
     });

     }
     public void showInputBox(String oldItem, final int index){
     final Dialog dialog=new Dialog(MainActivity.this);
    dialog.setContentView(R.layout.layout_dialog);
    dialog.setTitle("School details");
    r1 = (RatingBar)dialog.findViewById(R.id.ratingBar);
    r2 = (RatingBar)dialog.findViewById(R.id.ratingBar2);

    Button s=(Button)dialog.findViewById(R.id.button);
    s.setOnClickListener(new View.OnClickListener() {
        @Override
        public void onClick(View v) {
            f = (beh + b) / 2;
            a1.set(index, f.toString());
            a2.notifyDataSetChanged();
            dialog.dismiss();
        }
    });
    dialog.show();

    r1.setOnRatingBarChangeListener(new RatingBar.OnRatingBarChangeListener() {
        public void onRatingChanged(RatingBar ratingBar, float rating, boolean fromUser) {

            beh = rating;
            //String beh = Float.toString(rating);

            Toast.makeText(getApplicationContext(), beh.toString(), Toast.LENGTH_SHORT).show();

        }
       });
       r2.setOnRatingBarChangeListener(new     RatingBar.OnRatingBarChangeListener() {
        public void onRatingChanged(RatingBar ratingBar, float rating, boolean fromUser) {

             b = rating;
            //String b = Float.toString(rating);

            Toast.makeText(getApplicationContext(), b.toString(), Toast.LENGTH_SHORT).show();

        }
     });
   }

}

```