Including icons

Report a typo

The following method is used to display a message dialog box with an icon.

public void giveInfo() {
    ImageIcon cymbalIcon = new ImageIcon("cymbal.jpg");
    javax.swing.JOptionPane.showMessageDialog(
        null,
        "This is a cymbal.",
        "The Drummers",
        __________);
}

What do you pass as the fourth and fifth arguments to the showMessageDialog method to display an information message containing cymbalIcon?

Enter a short text
___

Create a free account to access the full topic