I have this code to show a dialog with singlechoice(radio) options.
AlertDialog ad = new AlertDialog.Builder(this) .setCancelable(false) .setIcon(R.drawable.
position of the selected element is already given in the onClick method. so we can directly access the the array and get the selected item without any hassle. in this case: seq[which] will be the selected item.