Java JOptionPane Error showErrorMessage(Component parentComponent, String message, String title)

Here you can find the source of showErrorMessage(Component parentComponent, String message, String title)

Description

show Error Message

License

Open Source License

Declaration

public static void showErrorMessage(Component parentComponent, String message, String title) 

Method Source Code


//package com.java2s;
//License from project: Open Source License 

import java.awt.Component;
import javax.swing.JOptionPane;

public class Main {
    public static void showErrorMessage(Component parentComponent, String message, String title) {
        showMessage(parentComponent, title, message, JOptionPane.ERROR_MESSAGE);
    }//  w ww  . ja  v  a  2  s .  co m

    public static void showErrorMessage(Component parentComponent, String message) {
        showErrorMessage(parentComponent, message, "Error");
    }

    public static void showErrorMessage(String message) {
        showErrorMessage(null, message);
    }

    public static void showMessage(Component parentComponent, String title, String message, int messageType) {
        JOptionPane.showMessageDialog(parentComponent, message, title, messageType);
    }
}

Related

  1. showErrorMessage(Component c, Exception e)
  2. showErrorMessage(Component parent, String message)
  3. showErrorMessage(Component parent, String str)
  4. showErrorMessage(Component parent, String str)
  5. showErrorMessage(Component parent, Throwable error)
  6. showErrorMessage(Component theParent, String theMessage)
  7. showErrorMessage(final JComponent parent, final String message, final String title)
  8. showErrorMessage(final Window aParent, final String aMessage)
  9. showErrorMessage(JFrame frame, String msg)