I'm getting this error message:
The method showMessageDialog(Component, Object, String, int, Icon) in the type
JOptionPane is not applicable for the arguments (JFrame, String, String, int, int, ImageIcon, String)
When I hover over JOptionPane.showMessageDialog. I followed the java tutorial and don't know what the problem is. Any idea?
Java tutorial: http://docs.oracle.com/javase/tutorial/uiswing/components/dialog.html#button
String option = "Restart";
JFrame frame = new JFrame();
ImageIcon ic = new ImageIcon("hangmanIcon.png");
JOptionPane.showMessageDialog(frame,
"He's dead, game over. The word was " + wordList[level],
"You Lost",
JOptionPane.OK_OPTION,
JOptionPane.INFORMATION_MESSAGE,
ic,
option);