Win a copy of Mesos in Action this week in the Cloud/Virtualizaton forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Applet will not draw correctly

 
Kevin Anderson
Greenhorn
Posts: 10
Android IntelliJ IDE Netbeans IDE
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hello all,

I have the following program that, when the applet loads, all I get is a white screen with 4 textboxes. I have even tried commenting everything except for the background line out but it still wont draw the background. Could you please point me in the direction of the error?




Thank you.
 
Ulf Dittmer
Rancher
Posts: 42967
73
  • Likes 1
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Swing applets should override paintComponent, not paint http://docs.oracle.com/javase/tutorial/uiswing/painting/
 
Kevin Anderson
Greenhorn
Posts: 10
Android IntelliJ IDE Netbeans IDE
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Ulf Dittmer wrote:Swing applets should override paintComponent, not paint http://docs.oracle.com/javase/tutorial/uiswing/painting/


It worked. Thank you.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic