Main.java Source code

Java tutorial

Introduction

Here is the source code for Main.java

Source

import java.awt.Component;

import javax.swing.JOptionPane;

public class Main {
    public static void main(String[] argv) throws Exception {
        int i = ok("Done.");
        System.out.println("ret : " + i);
    }

    public static int ok(String theMessage) {
        int result = JOptionPane.showConfirmDialog((Component) null, theMessage, "alert",
                JOptionPane.DEFAULT_OPTION);
        return result;
    }
}