File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

JDialog

 
Friend
Ranch Hand
Posts: 67
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Can we insert a variable value in JOptionPane INFORMATION_MESSAGE dialog?
eg: count=1;
JOptionPane opt=new JOptionPane("+count",INFORMATION_MESSAGE);
Please.......
Thank you.
 
Cindy Glass
"The Hood"
Sheriff
Posts: 8521
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
As long as the first parameter is an object you can.
int count = 1;
String message = "The count is " + count;
JOptionPane opt=new JOptionPane(message, INFORMATION_MESSAGE);
 
With a little knowledge, a cast iron skillet is non-stick and lasts a lifetime.
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic