This week's book giveaways are in the Java EE and JavaScript forums.
We're giving away four copies each of The Java EE 7 Tutorial Volume 1 or Volume 2(winners choice) and jQuery UI in Action and have the authors on-line!
See this thread and this one for details.
The moose likes Beginning Java and the fly likes how to pass string value from one class to another Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of The Java EE 7 Tutorial Volume 1 or Volume 2 this week in the Java EE forum
or jQuery UI in Action in the JavaScript forum!
JavaRanch » Java Forums » Java » Beginning Java
Bookmark "how to pass string value from one class to another" Watch "how to pass string value from one class to another" New topic
Author

how to pass string value from one class to another

Benjamin Mulder
Greenhorn

Joined: Mar 13, 2004
Posts: 18
let me explain...

on classA I have:


I want to pass "hello world" to class B's jTextArea.

So I put on the button method.



but nothing happens on class B. jTextAreaClassB doesn't display "hello world" from jTextAreaClassA.

Thanks in advance

Ben
Mr. C Lamont Gilbert
Ranch Hand

Joined: Oct 05, 2001
Posts: 1170

What type of classes are these and in what way should it be displayed?
Layne Lund
Ranch Hand

Joined: Dec 06, 2001
Posts: 3061
Can you post more of the relevant code? Specifically, the declarations for the text fields involved here.

Layne


Java API Documentation
The Java Tutorial
 
 
subject: how to pass string value from one class to another