Java JOptionPane Warning warnMsg(String msg)

Here you can find the source of warnMsg(String msg)

Description

Warning message dialog

License

Open Source License

Parameter

Parameter Description
msg a parameter

Declaration

public static void warnMsg(String msg) 

Method Source Code

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

import javax.swing.JOptionPane;

public class Main {
    /**/*  w  ww  .ja v  a 2s . co m*/
     * Warning message dialog
     * 
     * @param msg
     */
    public static void warnMsg(String msg) {
        // Show it in a message box
        JOptionPane.showMessageDialog(null, msg, "Warning", JOptionPane.WARNING_MESSAGE);
        System.out.println(msg);
    }
}

Related

  1. warning(String msg)
  2. warning(String title, Object message, JComponent parent)
  3. warningMessage(Component component, String title, String message)
  4. warningMessage(final String title, final String content)
  5. warnMsg(final String msg)
  6. warnUser(Component parent, String message)