java me - How to autostart j2me application on foreground? -


i'm trying make j2me application auto-start when phone powered on. (the phone sonim xp1301.)

i added jad attribute "midlet-launch-power-on: yes", , application starts automatically stays on background... useless me because application ui-based , requires user interaction...

is there other jad attribute force application start in foreground, or j2me command bring application foreground?

edit: @ sonim developer site found this:

"we have our emulator library in can check whether application in background. once result can bring foreground

javabackgroundmode.isrunninginbackground(midlet m); used check whether midlet in background. if returns true means in background.

javabackgroundmode.bringtoforeground(this); used bring app foreground."

..but have no idea means... "emulator library"? can download , how use it? if try add line code:

javabackgroundmode.bringtoforeground(this);

..netbeans gives me error "cannot find sybmol: variable javabackgroundmode".

any ideas?

edit2: tested "push registry", not work. jad file looks this:

midlet-1: contactless,,example.contactless.contactlessdemo midlet-description: basic jsr257 contactless communication api demo. midlet-jar-size: 7738 midlet-jar-url: contactless.jar midlet-name: contactless midlet-permissions: javax.microedition.io.connector.file.read, javax.microedition.io.connector.file.write, javax.microedition.io.connector.http, javax.microedition.io.pushregistry midlet-push-1: autostart://:, contactless, * midlet-vendor: oracle midlet-version: 1.0 manifest-version: 1.0 microedition-configuration: cldc-1.1 microedition-profile: midp-2.0 

i never heard of midlet-launch-power-on before. had google learn sprint specific jad attribute.

try using standard way of auto-starting midlet: using pushregistry.

add these 2 lines in jad file instead, , remove midlet-launch-power-on attribute.

midlet-permissions: javax.microedition.io.pushregistry midlet-push-1: autostart://:,nameofmidlet,* 

see if makes difference.


Comments

Popular posts from this blog

Perl - how to grep a block of text from a file -

delphi - How to remove all the grips on a coolbar if I have several coolbands? -

javascript - Animating array of divs; only the final element is modified -