Here you can find the source of warnMsg(final String msg)
Parameter | Description |
---|---|
msg | a parameter |
public static void warnMsg(final String msg)
//package com.java2s; //License from project: Open Source License import javax.swing.JOptionPane; import javax.swing.SwingUtilities; public class Main { /**//from w ww . j av a2s . com * Warning message dialog * * @param msg */ public static void warnMsg(final String msg) { // Show it in a message box SwingUtilities.invokeLater(new Runnable() { public void run() { JOptionPane.showMessageDialog(null, msg, "Warning", JOptionPane.WARNING_MESSAGE); System.out.println(msg); } }); } }