J2ME and files
after I launch netbeans' mobile phone emulator and choose the middlet to execute in the emulator screen I got a question if I wish to execute a 'reading' operation on file. When I click 'Yes' the program instead of reading the file - immidiately ends working and comes back to midlet list... and the requested read of file and printing its conent doesn work...
below is the code:
I just had a quick read of your code and I do not see an instantiation of a TextBox object. So I guess the problem is that your TextBox object is null being returned from get_helloForm() method. In fact you are returning the global object helloTextBox which has not been instantiated. I think you should look to see if you are getting a nullPointerException.
Somewhere in your code you need:
helloTextBox = new TextBox(String title, String contents, int size, int type);
In your initialise() method you are:
I think that a null is being returned from get_helloForm() so a nullPointerException will be thrown when you try to setDisplay() in your initialize() method.