• 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

    .NET developer at thetrainline.com, previously web developer at MRM Meteorite. Awarded a PhD in misbehaviour detection in wireless ad-hoc networks.A keen C# ASP.net developer bridging the gap with APIs and JavaScript frameworks, one web app at a time.

    http://www.paulkiddie.com

    Leave a Reply

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