Android :: Use Map In My Application - Crashes With Error

Dec 7, 2009

I want to use a map in my application but I can't get it to run.

It always crashes with the following error:

CODE:.....

My XML file:

CODE:...................

My layout:

CODE:...............

In my code I add the map like this:

CODE:.............

Android :: use map in my application - crashes with error


Android :: App Crashes At Start And Gives A Force Close Error

Nov 19, 2010

VitaminTable.java:

CODE:.....

manifest file:

CODE:...........

main.xml:

CODE:...

I get the following error:

CODE:.......................

View 3 Replies View Related

Android : App Crashes - Can't Find A Java Method Despite - No Compiler Error

Aug 20, 2010

My Android app runs fine, but: If I insert a call to WebView.setScrollbarFadingEnabled, it crashes saying:

Could not find method android.webkit.WebView.setScrollbarFadingEnabled, referenced from [my class]
VFY: unable to resolve virtual method 289: Landroid/webkit/WebView;.setScrollbarFadingEnabled (Z)V


I am using Android 1.5, not a custom ROM. My app defines minSdkVersion="3" I always clean before compiling.

Is setScrollbarFadingEnabled unavailable in Android 1.5? If so, why don't I receive a compiler error?

View 1 Replies View Related

Sprint HTC Hero :: Yahoo Messenger Crashes - Fatal Error

Oct 27, 2009

I have been experiencing yahoo crashing when I close a conversation. I get a fatal error then it shuts down.

View 3 Replies View Related

Android :: Application Crashes Before It Starts

Nov 16, 2010

intentTest.java:
package intentTest.xyz.com;
import android.app.Activity;
import android.content.Intent;
import android.os.Bundle;
import android.view.View;
import android.widget.Button
public class intentTest extends Activity {
Button b;
/** Called when the activity is first created. */
@Override
public void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
setContentView(R.layout.main);
b = (Button) findViewById(R.id.b);
b.setOnClickListener( new View.OnClickListener() {
public void onClick(View view) {
Intent intent = new Intent(intentTest.this,seond.class );
startActivity(intent);
}});
}}
main.xml:
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:orientation="vertical"
android:layout_width="fill_parent"
android:layout_height="fill_parent"
>
<TextView
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:text="First screen"
/>
<Button
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:text="click"
android:name="@+id/b"
/>
</LinearLayout>
seond.java:
package intentTest.xyz.com;
import android.app.Activity;
import android.os.Bundle;
public class seond extends Activity{
/** Called when the activity is first created. */
@Override
public void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
setContentView(R.layout.second);
} }
second.xml:
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout
xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="wrap_content"
android:layout_height="wrap_content">
<TextView
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:text="second screen"
/>

manifest.xml:
<?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
package="intentTest.xyz.com"
android:versionCode="1"
android:versionName="1.0">
<application android:icon="@drawable/icon" android:label="@string/app_name">
<activity android:name=".intentTest"
android:label="@string/app_name">
<intent-filter>
<action android:name="android.intent.action.MAIN" />
<category android:name="android.intent.category.LAUNCHER" />
</intent-filter>
</activity>
<activity android:name=".seond"></activity>
</application>
</manifest>

I get the following error code:
11-16 01:26:07.156: ERROR/AndroidRuntime(779): Uncaught handler: thread main exiting due to uncaught exception
11-16 01:26:07.166: ERROR/AndroidRuntime(779): java.lang.RuntimeException: Unable to start activity ComponentInfo{intentTest.xyz.com/intentTest.xyz.com.intentTest}: java.lang.NullPointerException
11-16 01:26:07.166: ERROR/AndroidRuntime(779):
at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2401)
11-16 01:26:07.166: ERROR/AndroidRuntime(779):
at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2417)
11-16 01:26:07.166: ERROR/AndroidRuntime(779):
at android.app.ActivityThread.access$2100(ActivityThread.java:116)
11-16 01:26:07.166: ERROR/AndroidRuntime(779):
at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1794)
11-16 01:26:07.166: ERROR/AndroidRuntime(779):
at android.os.Handler.dispatchMessage(Handler.java:99)
11-16 01:26:07.166: ERROR/AndroidRuntime(779):
at android.os.Looper.loop(Looper.java:123)
11-16 01:26:07.166: ERROR/AndroidRuntime(779):
at android.app.ActivityThread.main(ActivityThread.java:4203)
11-16 01:26:07.166: ERROR/AndroidRuntime(779):
at java.lang.reflect.Method.invokeNative(Native Method)
11-16 01:26:07.166: ERROR/AndroidRuntime(779):
at java.lang.reflect.Method.invoke(Method.java:521)
11-16 01:26:07.166: ERROR/AndroidRuntime(779):
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:791)
11-16 01:26:07.166: ERROR/AndroidRuntime(779):
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:549)
11-16 01:26:07.166: ERROR/AndroidRuntime(779):
at dalvik.system.NativeStart.main(Native Method)
11-16 01:26:07.166: ERROR/AndroidRuntime(779): Caused by: java.lang.NullPointerException
11-16 01:26:07.166: ERROR/AndroidRuntime(779):
at intentTest.xyz.com.intentTest.onCreate(intentTest.java:18)
11-16 01:26:07.166: ERROR/AndroidRuntime(779):
at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1123)
11-16 01:26:07.166: ERROR/AndroidRuntime(779):
at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2364)
11-16 01:26:07.166: ERROR/AndroidRuntime(779):
... 11 more

View 5 Replies View Related

Android :: AlertDialog Crashes Application / Why Is So?

Jun 17, 2010

Can someone explain to me why this AlertDialog crashes? code...

View 1 Replies View Related

Android :: Toast Crashes Application / What To Do?

Nov 19, 2010

In my application I've implemented such that pressing the hardware volume keys displays a Toast with the current volume. Things go well most of the times. However long presses of the volume keys do succeed in crashing my application. The Log generated on crash is the following...

The approach I follow:
I have a toast Object and for every key press event detected I inflate a view ,set the view elements within, set it to the toast and then show the toast.

Any idea what is going wrong ? code...

View 1 Replies View Related

Android :: Application Crashes When Orientation Changes - Fix It?

May 26, 2010

My app crashes when the device orientation changes..Tried debugging on real device, but I have no clue where the crash exactly happens.. I would appreciate if someone could throw some light on this:

Below is the error log...

View 2 Replies View Related

Android :: Droid Application Crashes / What To Do?

Jan 18, 2010

I am trying to run an application on an android emulator, but it crashes. i am following a howto

i don't know what to do, it just crashes. other applications are running fine, can anyone tell me what i am doing wrong.here is the code...

View 4 Replies View Related

Android :: Camera Application Preview Crashes

Nov 24, 2010

So I started with this little write-up. I wanted to try to make an application that will take pictures while running in the background. To start though I wanted an application that once opened would simply take a picture every X seconds. After recreating the classes and methods show in the walk through below I ran into a few problems.
http://itp.nyu.edu/~sve204/mobilemedia_spring10/androidCamera101.pdf

For starters its seems that the onCreate function sets up all the objects for the application, but if you try to take a picture through any other method than onClick (IE directly calling it) the application actually hasn't setup the canvas or the preview yet.

My first question:
Is there any conditional method that you can setup that will wait till all the "onCreate" objects are created and their associated methods are called and finished? How do I wait for the application to finish putting together my surface and starting the cameras preview before automatically starting to take pictures?

My second question:
I am required to have a preview available to take pictures. Is there anyway to push this application to the back (IE running in the background) while still taking pictures? Is drawing to a canvas a requirement? (From what I can tell AFAIK, you are required to have a surfaceholder to start preview, when you put up another screen or application that pauses the current application and closes the surface/canvas you were presenting that preview on). If my understanding is correct on all of this the best I will be able to do is make a 1x1 pixel canvas that will still take up the screen due to the application being in the foreground.

My Third question:
Is there any way around this? Can you still utilize the camera in some fashion without requiring the preview be drawn?

View 1 Replies View Related

Android :: Camera Flash In 1.5 And 1.6 - Application Crashes

May 21, 2010

My app is using the camera on the phone. For phones w/ 2.0+ I have been able to activate the Flash. When I test on a phone with 1.5 OS on it the app crashes. I get: java.lang.reflect.InvocationTargetException and the Cause is java.lang.VerifyError: fishers.Nav.TakePicture$1
I assume because you have to access the flash differently in apps below 2.0? Can anyone give me some advice or links to examples showing how I could make it work over the whole range of Operating System version or is that just not at all do-able?

View 5 Replies View Related

Android :: Application Crashes When Trying To Play Media

Nov 11, 2010

I have a small mp3 (326KB) in my res/raw folder. In my code, I have mPlayer = MediaPlayer.create(FakeCallScreen.this, R.raw.sample); Player.prepare(); mPlayer.start(); The application just crashes when it tries to start the activity, I cannot figure out why.

View 2 Replies View Related

Android :: Application Crashes On Device Boot

Sep 20, 2010

I have registered a Receiver component for ON_BOOT_COMPLETED broadcast, in my application. The receiver does just prints a line in its onReceive() callback. However, when I boot the emulator(by executing Run as->Android application command from Eclipse) and unlock the screen on start up, I get an ANR dialog displayed in my Application. Following are the exceptions logged:

CODE:.............................

View 4 Replies View Related

Android :: Droid Application Crashes / What I Am Doing Wrong?

Jan 18, 2010

I am very new to android programming. i was following a guide in here, to create an application that shows the current location, i did as was told in the guide, but whenever i try to run it, it crashes, and asks for "force Close",
does somebody know what i am doing wrong? here is the code....

View 2 Replies View Related

Android :: Playing Multiple Sounds - Application Crashes

Jun 14, 2010

Shown are a few lines of code. If I play a single sound, it runs fine. Adding a second sound causes it to crash.

private SoundManager mSoundManager;
/** Called when the activity is first created. */
@Override public void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState); setContentView(R.layout.sos);
mSoundManager = new SoundManager(); mSoundManager.initSounds(getBaseContext());
mSoundManager.addSound(1,R.raw.dit); mSoundManager.addSound(1,R.raw.dah);
Button SoundButton = (Button)findViewById(R.id.SoundButton);
SoundButton.setOnClickListener(new OnClickListener() {
public void onClick(View v) { mSoundManager.playSound(1);
mSoundManager.playSound(2); } } ); }

View 1 Replies View Related

Android :: Market And Gmail Application Crashes On Launch

Jan 25, 2010

I have a G1 Android that's been rooted. My problem is that Market and Gmail crashes on launch. I also cannot get to the Data Synchronization page. It displays the page for a split second and then instantly closes out. Is there a way to reset the apps? I've tried factory reset and upgrading to a newer version of Cyanogen mod without success.

View 1 Replies View Related

Android :: Droid Application Crashes When Button Is Clicked / Fix It?

Oct 19, 2010

I am writing an android application that check the username and the password of the user once a login button is clicked

i run the app in the emulator and when i click on login button the application is crashed code...

View 1 Replies View Related

Android :: Screen Orientation / Shake Cellphone Crashes Application

Jan 15, 2010

I am having search application, which loads data retreived from the webservice.While application on create it shows progress dialog once its done with loading data it dismiss the progress dialog.problem is while loading if i change the orientation of the phone it works fine it try to load activity again, but if i start shaking the cellphone while it is loading data application get crashed, any solution?

View 1 Replies View Related

Android :: Crashes - Blank Screens When Running OpenGL Application

Jan 14, 2010

I'm nearly ready to publish my OpenGL game. I've been browsing this newsgroup and I've seen quite a few posts regarding crashes, blank screens, etc when running an OpenGL application on the Droid. I have three questions:

1) What are some common pitfalls that occur when trying to support the Droid/Nexus One? So far, I've tested my game on the Android 2.0 emulator (both WVGA & FWVGA) and everything works fine but I'm still paranoid.

2) I've placed my textures (png) in the assets folder. Will these images be pre-scaled automatically? I've read about specifying density independent images for resources but do the same rules apply for images stored in the assets folder? I'm afraid that pre-scaling will cause my textures to become non-power of 2.

3) What additional strategies have developers been taking to ensure their application works on the newer devices when they only have access to G1/G2 hardware?

View 10 Replies View Related

Android :: Simple Binary Text Clock - Application Crashes?

May 13, 2010

I want to create a simple android binary clock but my application crashes. I use 6 textview fields: 3 for the decimal and 3 for the binary representation of the current time (HH:mm:ss).

Here's the code:

CODE:........................

View 1 Replies View Related

Android :: Custom ListAdapter Extending BaseAdapter Crashes On Application Launch

Mar 23, 2010

Data being pulled from a local DB, then mapped using a cursor. Custom Adapter displays data similar to a ListView. As items are added/deleted from the DB, the adapter is supposed to refresh. The solution attempted below crashes the application at launch.

CODE:................

Errors:

CODE:.........................

View 3 Replies View Related

Android :: Application Crashes When User Presses Back Button / Where To Put Code?

Oct 6, 2010

First of all, maybe i went about this the wrong way in the first place. Situation is, i have a listview that when an item is clicked, it creates an intent and calls startActivityForResult() to another activity, to be able to edit the entries in the row. and that other activity after editing the required values, returns back to the calling activity, when the user clicks on a save button. The activity then uses the row Id to update the item.My problem now is that, if the user presses the BACK button instead, the application crashes. i have been looking around and see solutions like using Shared Preferences or onSavedInstanceState(), but i don't know where exactly i should be putting the code?

View 1 Replies View Related

HTC Incredible :: Frequent Crashes - Application

Aug 9, 2010

My Incredible has recently started to crash frequently and it seems to keep getting worse, now at least once or twice per day. It never crashes while I am using it, but I will go to check it later and it is dead. This is getting frustrating because I am missing calls without even knowing the phone is off. I either have to pop the battery or plug into power to force a reboot. Im not sure how to figure out what application might be causing the problem or if maybe it is a hardware issue. Does anyone have any idea what might be causing this, or know what I might do to start troubleshooting?

View 2 Replies View Related

Android :: Activity Crashes When Remote Service Crashes

Jul 16, 2010

I'm trying to understand remote services at the moment and everything works fine, i can start the service and know how to communicate with it through the AIDL-interface. My problem is that the service seems to still run in the same process like the activity it was started from, because the activity crashes too, if there is an error thrown in the Service.

I set the service process to remote ( android:process=":remote" ) so what am i doing wrong? Or what do i have to do to unbind the service-process completely from the activity-process?

View 1 Replies View Related

Android :: Android Bluetooth Crashes Application When Remote Device Closes Socket

Feb 16, 2010

I have connected my Android application to a Windows desktop machine via Bluetooth. The application interacts with the machine. At the end of the interaction the application on the desktop closes the socket that was opened between the Android and the desktop application. Right when socket.close() is called on the Windows machine my Android app pops open a dialog saying that the application has stopped unexpectedly and then it quits. I have a breakpoint on the line in the ConnectedThread (like in the BluetoothChat sample) where I read the InputStream on the Android and that is not hit. I also have a breakpoint in the catch statement for the try surrounding the place where I read the InputStream. That one also does not get hit. So I have no idea how I can catch this error. Is this a bug?

View 2 Replies View Related

Android :: Application Crashes While Doing AlertDialog.Builder Create() Method - Android

Aug 18, 2010

I am testing my application on an LG Eve phone. I have an application that tries to download something from the web, and when it throws an exception, it is supposed to launch an alertdialog saying that there was an error. When the phone has no wifi signal, the program crashes at builder.create() (see code below). However, when there is wifi signal, and the exception is thrown by something else (for instance, a typo in the url), the dialog launches the way it's supposed to. Any clue as to why this could be?

Code for onCreateDialog:

@Override
protected Dialog onCreateDialog(int id){

Dialog d = null;
switch (id){...............

View 1 Replies View Related

Android :: Android Market Place Crashes On Receiving Intent For An Application That Doesn't Exists In Marketplace

Mar 25, 2010

I am creating an application that checks the installation of a package and exits after launching the market-place with its id.

When I try to launch market place with id of an application say com.mybrowser.android by throwing an intent android.intent.action.VIEW with url: market://details?id=com.mybrowser.android, the market place application does launches but crashes after launch.

The application com.mybrowser.android doesn't exist on the market- place.

MyApplication is my application.

CODE:....................

However, when I try to launch the market place for a package that exists in the market place say com.opera.mini.android, everything works. Here is the log of this case:

CODE:.....................

View 6 Replies View Related

Android :: Why Does My Application Keep Getting Error And Then Quits?

Feb 11, 2010

I followed the developer guides on the Android website. It is working fine for a Hello World application but when I try and transition between Activities, my application keeps giving an "The application () has stopped unexpectedly. Please try again later." error and the application then quits. This happens when I click the button in the Subscribe Activity.

Subscribe.java
public class Subscribe extends Activity
implements OnClickListener {
/** Called when the activity is first created. */
@Override
public void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
setContentView(R.layout.subscribe);

Button subButton = (Button)findViewById(R.id.subscribe);
subButton.setOnClickListener(this);}

public void onClick(View v) {
Intent subIntent = new Intent(Subscribe.this,Subscribed.class);
startActivity(subIntent);}}

Subscribed.java
public class Subscribed extends Activity {/** Called when the activity is first created. */ @Override
public void onCreate(Bundle savedInstanceState) {super.onCreate(savedInstanceState);
setContentView(R.layout.subscribed);}}
Logcat Log File

View 2 Replies View Related

Android :: Application Gives Error - How To Debug?

Nov 9, 2009

I have a user that says my application gives him an error on the Samsung Galaxy (it works fine one the G1). How can I debug this issue? Is there an accurate emulator/simulator? Can someone try it (Bendometer is the app)?

View 2 Replies View Related

Android :: Close Application On Error

Apr 18, 2010

I'm currently writing an application for the Android platform that requires a mounted SD card (or ExternalStorage). I know that it might not be the best way to require something like that, but the application will work with quite a lot of data, and I don't even want to think about storing that on the device storage.Anyway, to ensure that the application wont run without the external storage, I do a quick check in the activities onCreate method. If the card is not mounted, I want to display an error message and then quit the application.When I run the application, and the exception gets raised (I raise it manually to check if everything works), the error message is displayed correctly. However when I press the button, the application closes and I get an Android error, that the application was closed unexpectedly (and I should force exit).I read some topics before on closing an application, and I know that it maybe shouldn't happen like that. But how should I instead prevent the application from continuing to run? How do you close the application correctly when an error occurs?

View 1 Replies View Related







Copyrights 2005-15 www.BigResource.com, All rights reserved