• Creating a MessageBox in Java

    by  • January 5, 2010 • .net, c#, java • 0 Comments

    I wanted to see if there was a Java equivalent of .NET’s MessageBox class. Turns out there is but it’s a little more hidden away as a static method on JOptionPane, so I’ve pasted the code here for referring to it in the future:

    JOptionPane.showMessageDialog(null,"message","title"));

    This creates and shows a message dialog with no parent with message “message and the title “title”.

    About

    Web Developer for MRM Meteorite. Awarded a PhD in research into novel techniques to detect misbehaviour in peer-to-peer wireless networks. Experienced C# and ASP.net developer, with an interest in SOA, RIA and moble app development.

    http://www.paulkiddie.com

    Leave a Reply

    Your email address will not be published. Required fields are marked *