Código Java:
Ver original
// TODO Auto-generated method stub checked = ListviewProductos.getCheckedItemPositions(); ArrayList<String> selectedItems = new ArrayList<String>(); for (int i = 0; i < checked.size(); i++) { // Item position in adapter int position = checked.keyAt(i); boolean ischecked = checked.valueAt(i); // Add sport if it is checked i.e.) == TRUE! if (selectedItems.isEmpty() || ischecked == false || checked==null) { Toast.makeText(getApplicationContext(), "Selecciona Una Opcion", Toast.LENGTH_SHORT) .show(); } else if (checked.valueAt(i) == false) { Toast.makeText(getApplicationContext(), "Selecciona Una Opcion", Toast.LENGTH_SHORT) .show(); } else if (checked.valueAt(i) == true) { selectedItems.add(arrayAdapter.getItem(position)); for (int j = 0; j < selectedItems.size(); j++) { outputStrArr[j] = selectedItems.get(j); } intent = new Intent(getApplicationContext(), ViewPedido.class); Bundle b = new Bundle(); b.putStringArray("selectedItems", outputStrArr); b.putString("cedcliente", cedcli); b.putString("codcliente", codcli); b.putString("nomcliente", nomcli); b.putString("dircliente", dircli); b.putString("corcliente", corcli); intent.putExtras(b); startActivity(intent); finish(); } } } });
Alguien me podria ayudar para saber en donde estoy cometiendo el error.
Saludos.