0

I'm trying to make a custom dialog with a list view from another xml file but I'm running into some trouble. Here is my code:

AlertDialog.Builder dialogBuilder = new AlertDialog.Builder(this);
LayoutInflater inflater = this.getLayoutInflater();
View dialogView = inflater.inflate(R.layout.dialog, null);
dialogBuilder.setView(dialogView);

AlertDialog alertDialog = dialogBuilder.create();

The program is saying that it cannot resolve the symbol "setView" Also, it is saying "Unknown class dialogView" I have looked online at several forums and still cannot find the answer to this problem. I would appreciate any help you guys could give.

logicalien
  • 11
  • 2

0 Answers0