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

why does this code doesn't work

 
Dominik Pawlocki
Greenhorn
Posts: 6
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Why does this code doesn't work??? (it doesn't show wordHello!! in TextArea and it doesn't show wordControl)

[This message has been edited by Cindy Glass (edited December 17, 2001).]
 
jason adam
Chicken Farmer ()
Ranch Hand
Posts: 1932
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
You have a few things wrong with your program. First, you call the class Object, but in your main() method you create an object of type Obiekt. I would refrain from calling any class you create Object. Change your class declaration to Obiekt, and make sure you change your public Object() constructor to public Obiekt().
Second, in your Action class, you instantiate a whole new object class. This is not the same object that you create in main and set to show. What you should do is make your Action class an inner class (defined within your Obiekt class), and just call the show() method (you could do either show() or this.show() ).
Make those changes, and you should get the response you are expecting.
Jason
 
With a little knowledge, a cast iron skillet is non-stick and lasts a lifetime.
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic