Note that there are some explanatory texts on larger screens.

plurals
  1. POquestion for terminate app in j2me but it doesnt mean quit from application
    text
    copied!<p>i have case in j2me .. i want terminate when app in process execute code. this is my simple code.</p> <pre><code>else if (c == cmdStop) { //command berhenti browser.stop(); } </code></pre> <hr> <pre><code> public void stop(){ // No errors int errorCode = 0; // An error occurred errorCode = -1; // Terminate System.exit(errorCode); } </code></pre> <p>the problem is when i try to terminate app, the app still worked or continue execute and ignore function system.exit.</p> <p>still excecute this code </p> <pre><code>private void paintParserScreen(Graphics g){ int w = width; int h = fontHeight+2; int x = 0; int y = height - h; int curLoaded = 0; int value = 0; int iPercent = 0; if(maxElementNum!=0){ curLoaded = wapRender.getCurLoadedTag(); value = curLoaded * 100 / maxElementNum; iPercent = (curLoaded * (w - 2)) / maxElementNum; } g.setColor(0x808080); g.fillRect(x, y, w, h); g.setColor(0x0000ff); g.fillRect(x + 1, y + 1, iPercent - 2, h - 1); g.setColor(0xffffff); g.drawString("proses..." + value+"%", width&gt;&gt;1, y + 1, Graphics.TOP|Graphics.HCENTER); } </code></pre> <p>and they said</p> <pre><code>java.lang.SecurityException: MIDP lifecycle does not support system exit. at java.lang.Runtime.exit(+9) at java.lang.System.exit(+7) at com.gameislive.browser.Browser.stop(+8) at Tampilkan.commandAction(+147) at javax.microedition.lcdui.Display$DisplayAccessor.commandAction(+282) at javax.microedition.lcdui.Display$DisplayManagerImpl.commandAction(+10) at com.sun.midp.lcdui.DefaultEventHandler.commandEvent(+68) at com.sun.midp.lcdui.AutomatedEventHandler.commandEvent(+47) at com.sun.midp.lcdui.DefaultEventHandler$QueuedEventHandler.run(+250) </code></pre> <p>please help me what should i do for this case?</p>
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload