This code is part of a context menu that pops up when a listview is clicked. I am trying to get the user result through whether or not a CheckBox is checked or not. The problem is that the string I am creating cannot be resolved.
Here is the code:
final CheckBox input11 = (CheckBox) textEntryView2.findViewById(R.id.checkBoxResult);
alert2.setPositiveButton("Confirm", new DialogInterface.OnClickListener() {
public void onClick(DialogInterface dialog, int whichButton) {
String blazeIt = lvItems.getItemAtPosition(menuInfo.position).toString();
String turntupheho = blazeIt.replace(" --COMPLETE", "");
String evenmoreturnt = turntupheho.replace(" --INCOMPLETE", "");
if (input11.isChecked()) {
String bigbutt = " --COMPLETE";
} else {
String bigbutt = " -INCOMPLETE";
}
items.set(menuInfo.position, evenmoreturnt + bigbutt); //Cannot resolve symbol 'bigbutt'
itemsAdapter.notifyDataSetChanged();
writeItems();
}
}
);
EDIT: Sorry simple mistake (forgot to declare String); I'm still learning. Thank you everyone for the quick responses.