• Post Reply Bookmark Topic Watch Topic
  • New Topic

setDefaultCloseOperation...void type and non static method errors.  RSS feed

 
john price
Ranch Hand
Posts: 495
Chrome Java Linux
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I was wondering if it was possible how to do a custom setDefaultCloseOperation...
I tried this:

and got this error:

How could I make this work? Could I make update() and another method static? Why would I have a return type for a close operation?
Thanks,
cc11rocks aka John Price
 
Rob Camick
Ranch Hand
Posts: 2756
12
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
???
 
john price
Ranch Hand
Posts: 495
Chrome Java Linux
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
When the system receives a message to close, run the method update() and System.exit(0)...
 
Rob Camick
Ranch Hand
Posts: 2756
12
  • Likes 1
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Closing an Application
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!