Smith Jon

Greenhorn
+ Follow
since Jan 08, 2006
Merit badge: grant badges
For More
Cows and Likes
Cows
Total received
0
In last 30 days
0
Total given
0
Likes
Total received
0
Received in last 30 days
0
Total given
0
Given in last 30 days
0
Forums and Threads
Scavenger Hunt
expand Ranch Hand Scavenger Hunt
expand Greenhorn Scavenger Hunt

Recent posts by Smith Jon

My java version is "1.6.0_13"
Java<TM> SE Runtime Environment <build 1.6.0_13-b03>
Java HotSpot<TM> Client UM <build 11.3-b02,mixed mode, sharing>
Today, I can't open the MyEclipse 6.5 software ,there is a error called "Could not create the java vitrual machine?".My JRE is j2se1.6_14.I try to restore it ,but I can't .so I need some help,who can help me?
/*
* Rhyme2.java
*
* created on 2006-7-3 at 15:41
*/
import java.awt.*;
import java.awt.event.*;
public class Rhyme2 extends Frame implements ActionListener
{
String FIRST="One two,buckle my shoe";
String SECOND="Three four,close the door";
String THIRD="Five six,pick up sticks";
Button btnOK=new Button("OK");


public void createInterface()
{
setLayout(new GridLayout(0,1));
add(new Label(FIRST));
add(new Label(SECOND));
add(new Label(THIRD));
add(btnOK);
btnOK.addActionListener(this);
addWindowListener(new WindowAdapter()
{
public void WindowClosing(WindowEvent event)
{
dispose();
System.exit(0);
}
});
pack();
show();

}
public static void main(String args[])
{

Rhyme2 rhy=new Rhyme2();
rhy.createInterface();

}
public void actionPerformed(ActionEvent event)
{
Object objSource=event.getSource();
if(objSource==btnOK) dispose();
}



}
I compile and run the program on the JCreator Pro software,but it cannot close the close box.Then i press the 'Ok' button ,it can dipose the frame.
who can tell me why?
who can help me?
17 years ago