Skip to main content
June 22, 2011
Question

“Your application is not responding, force close or wait”

  • June 22, 2011
  • 1 reply
  • 1788 views
During some heavy synchronous DB calls on Android, I am encountering:
“Your application is not responding, force close or  wait” messages.
Allowing the app to Wait – (clicking Wait)  keeps things going,
at least until the next “Your  application is not responding, force close or wait” pops  up.
Short of re-writing everything for  asynchronous DB access;
are there any AS3 API calls that can be  made to either:
1. programmatically tell AIR to wait,  or...
2. give AIR a slice of processing time so  that it can do what it needs to;
   to know everything is still  running?
Thanks

Tools:

Flash Pro CS5

All AS3, no timeline code.

Target: Android

Platform: Motorola XOOM

Current FPS is 29.

scriptTimeoutLimit has been set to 255.

This had no effect.

(But I think this may just be for print jobs anyway).

This topic has been closed for replies.

1 reply

Participating Frequently
June 26, 2011

Hello,

what you're seeing is ANR (application not responding) dialog and it could be shown in every case when application is assumed to not accept user input (this is deducted by system itself):

http://developer.android.com/guide/practices/design/responsiveness.html

You actually have no other choice I think then to roll asynchronous version(s) as database operations are one of I/O operations that easily blocks user interface (the answer to your questions is *no* in both cases - there is multithread route in native applications not available yet in AIR runtime - we are to use asynchronous solutions). You could take that article as guide:

http://www.adobe.com/devnet/air/flex/articles/air_sql_operations.html

(btw: you could take some solutions from "Processing data" section like processing data in chunks to be applied in your existing synchronous code before going into full asynchronous route I think).

hth,

regards,

Peter