According to the official MIDP2 API for TextField class:
public void setString(String text)
- Sets the contents of the TextField as a string value, replacing the previous contents.
Parameters:
text - the new value of the TextField, or null if the TextField is to be made empty
microemulator was throwing NullPointerException when null was being passed to setString() method. The patch (attached) now fixes this.
Fixed TextField.java