Hi,

When i try to insert j2me list control in my project. i develop the project through net bean 7.1. It does not show any error and not show list control in form.
Here the code.

import java.io.IOException;
import javax.microedition.lcdui.*;
import javax.microedition.midlet.*;
public class mylist extends MIDlet implements CommandListener {
private Display display;
private List list;
private Command exit, next;
public mylist(){
list=new List("Check",List.EXCLUSIVE);

}
public void commandAction(Command c, Displayable s){
int id=list.getSelectedIndex();
if(c.equals("next")){
Alert alert = new Alert("Selected", "You have selected: " + list.getString(id)

+ ".", null, AlertType.INFO);
display.setCurrent(alert, list);
}
else if(c == exit){
destroyApp(true);
}
}
public void startApp(){
display = Display.getDisplay(this);
list.append("Ok", null);
list.append("No",null);
next = new Command("Select", Command.SCREEN, 0);
exit = new Command("Exit", Command.EXIT, 0);
list.addCommand(next);
list.addCommand(exit);
list.setCommandListener(this);
display.setCurrent(list);
}
public void pauseApp(){

}
public void destroyApp(boolean unconditional){
notifyDestroyed();
}

}