BlackBerry Forums Support Community
              

Closed Thread
 
Thread Tools
Old 05-25-2010, 07:49 AM   #1
BB1364
Thumbs Must Hurt
 
Join Date: Oct 2007
Model: 7100i
PIN: N/A
Carrier: Dont know
Posts: 195
Default Sending GPS location info to server after device reboot.

Please Login to Remove!

Hi
I have a application which constanly sends GPS location of the device to a server. The app works fine if the device is not rebooted.

Once the device is rebooted and before opening the application i still want to send the GPS location to the server. So i have started a thread which initializes the location provider and criteria for collecting the GPS info from the device in the alternate entry to send the GPS location to the server.

But it always says Exceptionjava.lang.IllegalStateException: no application instance

Does anyone have any idea for this issue.

Thanks

.
Offline  
Old 05-25-2010, 09:01 AM   #2
Dougsg38p
BlackBerry Extraordinaire
 
Join Date: Mar 2008
Location: Austin, TX
Model: 9700
PIN: N/A
Carrier: T-Mobile
Posts: 1,644
Default

This means that you are attempting something that requires your app to be a Application instance, or a UiApplication instance, but you have not yet entered the event dispatcher.
Offline  
Old 05-25-2010, 09:07 AM   #3
BB1364
Thumbs Must Hurt
 
Join Date: Oct 2007
Model: 7100i
PIN: N/A
Carrier: Dont know
Posts: 195
Default

Hi Dougsg38p

Thanks for your reply. But does it mean i need to start the event dispatcher when the application start from the alternate entry? Do you have any solution for this?

Thanks
Offline  
Old 05-25-2010, 10:16 AM   #4
Dougsg38p
BlackBerry Extraordinaire
 
Join Date: Mar 2008
Location: Austin, TX
Model: 9700
PIN: N/A
Carrier: T-Mobile
Posts: 1,644
Default

Whatever it is you are doing, you'll have to wait until the app enters the event dispatcher.

I can't comment on when because I don't have any information about how your code is structured.

You can probably start the program, start a background thread for the HTTP traffic, then call requestBackground(). This would insure that you have an app instance but are not visible to the user.
Offline  
Old 06-11-2010, 10:27 PM   #5
BB1364
Thumbs Must Hurt
 
Join Date: Oct 2007
Model: 7100i
PIN: N/A
Carrier: Dont know
Posts: 195
Default

Thank you very Much will defintely try it.
Offline  
Closed Thread



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


Bulwark LNS2 Nomex IIIA FR Insulated Vest XL Long Navy Arc Flash CAT 4 picture

Bulwark LNS2 Nomex IIIA FR Insulated Vest XL Long Navy Arc Flash CAT 4

$39.99



ZIP System Flashing Tape 3.75

ZIP System Flashing Tape 3.75" x 90' (12 Rolls) Huber ZIP Tape Full Case

$289.99



ZIP System Liquid Flash 10.3 oz. Cartridge ***10pk*** picture

ZIP System Liquid Flash 10.3 oz. Cartridge ***10pk***

$190.00



LG ARC FLASH KIT,40 CAL,NSA, National Safety Apparel, ENESPRO,NAVY, KIT4SC40NGLG picture

LG ARC FLASH KIT,40 CAL,NSA, National Safety Apparel, ENESPRO,NAVY, KIT4SC40NGLG

$750.00



Flash Nailer Attachment picture

Flash Nailer Attachment

$17.00



Arc Guard Flash Protective Face Shield. NR7003 RG/M picture

Arc Guard Flash Protective Face Shield. NR7003 RG/M

$100.00







Copyright © 2004-2016 BlackBerryForums.com.
The names RIM © and BlackBerry © are registered Trademarks of BlackBerry Inc.