• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

ToolTipText doesn't work

 
Greenhorn
Posts: 4
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hey there,
I hope you can help me out.
I want to add an ToolTipText to my applet.
I want to connect it to this object:
" tfName " ( A TextField). The textfield is visable, and works fine.
tfName.setToolTipText("Enter your name!");
give me an :
game.java: 46 cannot resolve symbol
symbol: method setToolTipText ( java.lang.String)
location: class java.awt.Textfield
tfName.setToolTipText("Enter your name!");
^
1 error
Please help me !
imported :
awt,awt.event,applet,net,javax.swing

greetz,
Bas
 
Ranch Hand
Posts: 54
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Instead of using java.awt.TextField try using javax.swing.JTextField.
TextField doesn't have a method called setToolTipText, but JTextField does.
Anothertip is this link.
Regards,
Marcel
reply
    Bookmark Topic Watch Topic
  • New Topic