Android :: Cancelling Of BackgroundAsyncTask In Activity
Oct 23, 2010
I have activity class running infinite loop in BackgroundAsyncTask (see below) I have a problem trying to "finish" this activity, when i press "btnClose" the activity window disappears, but when i try to re-start this activity from "Applications" group i have "null pointer exception" java.lang.RuntimeException: An error occured while executing doInBackground
CODE:...............
Where is null pointer exception coming from and how to do it right? line 224 corresponds to inner class BackgroundAsyncTask but what is causing null pointer exception? I tried to check for passed params in doInBackground: "if (params == null) return" - no difference.
CODE:................
View 3 Replies
Jan 29, 2010
Follow the HelloAndroid Tutorials by use Eclipse. After run HelloAndroid, the AVD 'xian_avd2' lunched, but stop there, no " Hello, Android". displayed on AVD. Looks like Waiting for HOME ('android.process.acore') to be launched...
Not know how to resolve this,
CODE:..............
View 1 Replies
View Related
Jun 23, 2010
I am canceling my AT&T contract w/iPhone for one of the Droids and BETTER reception. I'd love to get a Droid X, even if I have to wait. My question is, do they ever offer promotions like the one going on with the Droid right now for buy 1 get 1 free for their new phones? My wife and I are both looking into them but if there is no chance of this we will probably just get the Motorola Droid buy 1 get 1 free deal while it's still there.
View 1 Replies
View Related
Aug 13, 2009
I'm writing an application that demonstrates various gesture algorithms, and Toast after each one is detected. of course if the user goes all hogwild then the Toasts back up. can i flush the Toast queue somehow?
View 2 Replies
View Related
Apr 20, 2010
Does the incredible have the same noise cancelling that the nexus one has?
View 4 Replies
View Related
Apr 24, 2010
Unless I can get a conformation that it's in the 2-3 day stage and not the waiting stage I'm just canceling. I've been in the telecom business too long to see a disaster in the making. It's going to take more time for the phones to port numbers and ship than that window would allow.
View 20 Replies
View Related
Apr 22, 2010
One thing the Incredible doesn't have that the Nexus One does is the fancy noise cancellation technology. I'm a little surprised at how little this is being mentioned and I'm also puzzled at why this feature was dropped since on paper it sounds like such a good thing. Does anyone have experience with how well it worked? Did it not work out as well as planned, was it a cost saving measure to drop it, or does nobody actually talk directly into their phone anymore?
View 4 Replies
View Related
Sep 17, 2010
I missed something, but is there a way I can cancel autosuggestions when typing? Examples:
So this example happened to me frequently before 2.2, but I haven't been able to reproduce it now. I'm trying to search for "wifi" in google, so I type "wifi". The first autosuggestion is "wifi android n router", because that's one of my past searches. "wifi" alone is NOT a suggestion. If I hit enter it'll search for the whole phrase. I don't see any way to get just what I typed to be submitted to the search. I press the little down arrow in the suggestions box, but all that comes up is a bunch of other searches, urls, but nothing that says just "wifi".
Another example, today I was doing one of those captcha things. I type in the nonsense letters in the picture, and Android suggests similar words. This time, the nonsense word was on the list. But if I click it, bam, it adds to my dictionary. If I don't, there's no way to get out of autosuggest -- I tried hiding the keyboard (without hitting enter), but that changed my typing to the first suggestion.
View 1 Replies
View Related
Sep 9, 2010
I don't know how many of you have actually tested the limits of the background cancelling mics on the DX, but I have. I was prompted to test it while speaking to a client while walking my dog the other day.. as a lawn worker passed me with a leaf blower, I apologized to my client for the noise. "His response, with leaf blower right next to me, was, "Noise? You aren't sitting at your desk? I don't hear anything but your voice."
So ok... wow. Now my working from home butt is unleashed from the desk which is ... AWESOME!
So I decided to test the limits... I called my voicemail while standing in a packed bar a couple nights ago. Thumping music, people all around laughing and shouting, crazy scene. The result? At the beginning, before I spoke, you can faintly hear the music... then... nothing but my voice. It's the most amazing thing I've ever heard (or, I guess, not heard).
Anyhow.. I think Motorola should be advertising this! I can see the commercial now... business dude on a golf course while boss calls and doesn't know... man in a bar and wife can't tell (remember the old Capitan Morgan ad?)
View 36 Replies
View Related
Aug 2, 2010
Whenever the memory needs to be reclaimed, the process is being killed by Activity Manager Service in killPidsForProcess. I have a back button in my activity window on right corner of the title bar.
I want to kill the activity completely on clicking the close button. Can I reuse the same function and will it have any major effect? Please help me out in this.
View 3 Replies
View Related
Jan 20, 2009
I want to be able to show the Battery Info activity in my app, which shows things such as the exact level, battery health, etc.I'm not sure how I can get it, though a few applications such as Power Manager, Any Cut, etc. show this screen as well. I found in the source code of Settings this intent in a file called testing_settings.xml,But I don't know how to use it. I would guess from the fact that Any Cut has a list of activities, that a list of said activities exists somewhere, and therefore an easy way to access them exists, but I haven't found it.
View 3 Replies
View Related
Aug 27, 2010
My app is comprised of a set of reusable Activities that other apps can reuse. For various reasons, I would like my Activities to be launched in context of the invoking Activity's process, instead of always being launched in my Activity's process (default behavior on Android). How can I achieve this?
View 1 Replies
View Related
Mar 3, 2010
So I have an app with Activity A. The layout on the activity is dynamic genearted. So it's possible that on Activity A a user hits a button that goes to "A" and the new page looks different, then a user clicks another button to go to "A" again. Now I have 2 Activities in the history stack. A, A, and currently on A. Is it possible that if a user clicks a button that the whole Activity stack is cleared in a scenario such as this?
View 5 Replies
View Related
Apr 27, 2010
How to finish any previous activity in application stack (at any level , I mean not immediate parent) , from current activity like on some particular event I want to invalidate this previous activity?
View 1 Replies
View Related
Jul 26, 2010
How can I make sure I only retain one copy of an activity on the stack when called from non-activity? When called from an activity I can just add the FLAG_ACTIVITY_REORDER_TO_FRONT flag to the Intent, but how can I do this from e.g. a widget or a notification?
View 1 Replies
View Related
Aug 21, 2009
I have a problem to start/create Activity in landscape mode. My Activity need to start in landscape mode and be used in landscape mode by users. So far, I used setRequestedOrientation(ActivityInfo.SCREEN_ORIENTATION_LANDSCAPE) to force screen orientation of my Activity to landscape mode in onCreate() method.
In addition to this screen mode requirement, my application need to start another background thread in onResume() method, and this thread takes some seconds in order to finish an initialization process, and it is not desirable to to stop/restart this thread's service during the initialization process.
However setRequestedOrientation (ActivityInfo.SCREEN_ORIENTATION_LANDSCAPE) forces my Activity restart in a very little while (means onCreate->onResume->onPause->onStop are executed twice at the first place). As a result, my background thread be stopped/restarted during the initialization process, and this makes me a mess at this moment.
View 3 Replies
View Related
Nov 5, 2010
The default behavior from my observation is if current activity force closes Android tries to go to previous activity on stack How can I control this behavior? I want force close to close all activities
View 2 Replies
View Related
Jul 19, 2010
Im writing a program that offers a quick reply dialog upon receipt of an SMS.
However, I am getting an unexpected result. When I receieve an SMS, the appropriate dialog activity comes up displaying the correct phone number and message, however there is a second activity behind it that is the 'default' activity in my program (it is what opens when i launch my application)
I do not want this second activity to come up. The quick reply activity should come up by itself over top of whatever the user was doing before.
The 'floating' activity:
CODE:.........
The call to the activity inside an onReceive()
CODE:..............
The Manifest:
CODE:.................
View 1 Replies
View Related
May 16, 2010
I'm writing an application that starts with a loading activity. In the loading activity the app requests html from web and parses the html, then it sends the parsing result to the main activity. The main activity has several tabs, and contents of these tabs are based on the result of parsing.For example, the result of parsing is a list of strings ["apple", "banana", "orange"], and I need to pass this list to main activity, so that the main activity can create three tabs named after three fruits.I would like to know if there is any way to pass a list of strings among activities, BTW, is it the common way of do this?
View 2 Replies
View Related
Mar 3, 2010
example scenario is: from login screen - main screen - then when i clicked a hide button inside the mainscreen, the app will need to go in the home screen, and when im going to click the app again the main screen would be called and not the login screen
View 3 Replies
View Related
Feb 18, 2010
have an activity which launches another activity, via a button click. By default, on newer OS versions of android, the OS will animate the new activity sliding in from right to left.Is there a way to disable this animation? I just want the new activity to appear without any sort of animation.
View 5 Replies
View Related
Aug 12, 2010
I'm working on an app that launches the browser activity to perform a Twitter OAuth authorization. This process uses a callback url which will re-launch the activity that started the browser activity in the first place.My problem is that the browser pages remain in the history stack and when the user then clicks back from the preferences activity that launched the browser in the first place, they don't go back to the app's main activity, but instead are brought back to the browser. I've tried adding flags to the launching intent to prevent history and reset on clear, but it doesn't seem to work when running on my phone, only on the emulators.
View 1 Replies
View Related
Jan 26, 2009
I have an application with contains multiple activities. The main activity will start the others ( use startActivity() ) depends on user event, when an activity close, it calls finish() and return back to main activity. It appears to behavior like that.
However, the "problem" I see is main activity's onCreate function is called every time. I think the the main activity should be placed in the activity stack and simply push to front when others exit, therefore only onResume, onStart are called. Is there some flag I need to set or I misunderstand the activity behaviro?
In child activity, besides calling finish() or startActivity for main activity, what is other way to move main activity to front?
View 2 Replies
View Related
Jan 10, 2010
I created an application which enables the user to set whether he wants to receive notification while the application runs in background mode. If the notifications are enabled an activity should be started (the dialog should appear on the screen).
I tried to enabled it the following way:
CODE:...........
This is the method from main activity. When onPause() is executed isRunningInBackground is set true.
When I tried to debug it when the main application was running in the background the line
startActivity(intent) had no effect (the activity didn't appear).
Does anyone know how to midify the logic in order to start an activity from the main activity when the main activity is running in the background (after onPause() is called)?
View 1 Replies
View Related
Nov 9, 2010
I have an activity that starts a long-running service which in turn adds an icon to the status bar. When the activity gets invisible, e.g. by pressing the Home button, and the pressing the icon in the status bar a new activity is created instead of showing the already created activity. If you now press the back button the new activity is destroyed and the activity created in the first place gets visible. How do I make the invisible activity brought to front when pressing the icon in the status bar instead of creating a new activity?
View 1 Replies
View Related
Dec 4, 2009
Need an example of how to create/start a new activity from the main activity. I have a button click event on the main layout. Originally I just used setContentView(R.layout.secondactivity); which brings up the layout but I don't think that is correct since the secondactivity class is not instantiated at this point yet. I have looked for such an example and can not find one.
View 3 Replies
View Related
Jan 10, 2010
I hav an app that is like a relational database. There is a main app activity that users manage things with. There is also a widget that will display important info and add data to the database. When the widget is clicked, a configure class displays a way for the user to edit data. When the configure activity is done, the widget is updated and instead of going back to the home screen, the apps main activity is started. I can't find where the main activity is being called from. Wouldn't I have to create an intent and start Activity() to get this behavior? When done updating, I want the home screen and not my app.
View 3 Replies
View Related
Mar 3, 2010
example scenario is: from login screen - main screen - then when i clicked a hide button the app will go to home screen, and when im going to click the app again the main screen would be called.
View 2 Replies
View Related
Sep 28, 2009
I created an application which is asynchronously communicating with the server. When the application makes a server request a new dialog (activity) with "loading" notification is created. The main activity implements methods for handling server responses and I would like to close the foreground activity when the main activity receives the answer from the server.
View 1 Replies
View Related
Jan 21, 2010
When views with different type have same id and screen orientation changes,
either java.lang.ClassCastException: android.view.AbsSavedState$1 or java.lang.IllegalArgumentException: Wrong state class -- expecting View State will occur. (depends on the view's order)
Because View.dispatchRestoreInstanceState() checks id only.
You may wonder why anyone would make views with different type to have same id.
But it can happen when you use tab activity.
Imagine you have tab activity with two children activity.
Tab1 is ListActivity and Tab2 is ExpandableListActivity.
Both activity have id of "@android:id/list" but the type of view is different.
This means we cannot use ListActivity & ExpandableListActivit at the same in one tab activity.
View 4 Replies
View Related