• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

displaying a swing Transformeredit

 
terry oliver
Greenhorn
Posts: 22
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi

i have a swing class named EngineeringData, and havemade another swing class TransformerEdit I would like to dispay the TransformerEdit when the edit button is pressed in engineering data I am having some problems can anyone help thanks

Olly
 
terry oliver
Greenhorn
Posts: 22
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
here is a part of my code whats wrong

private Vector secOhmsTemp;
private Vector secCmTemp;
TransformerEdit et;
//-----
// End of variables declaration


public engineeringDataSheet()
{
super();
initializeComponent();

TransformerEdit te = new TransformerEdit();
 
Campbell Ritchie
Sheriff
Pie
Posts: 50168
79
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
What are you doing about the edit button? Have you added a Listener to it? Do you know about Listeners?

Go through the Swing forum and look for threads like this, and this, where the conepts of Listeners have been discussed recently.
 
Campbell Ritchie
Sheriff
Pie
Posts: 50168
79
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
. . . and why are you declaring a field inside the constructor? That is a sure-fire recipe for NullPointerExceptions later on.
 
Ilja Preuss
author
Sheriff
Posts: 14112
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
What exactly is the problem you are experiencing???
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic