Note that there are some explanatory texts on larger screens.

plurals
  1. POGetting an exception when trying to add an account in Android
    primarykey
    data
    text
    <p>I'm attempting to create a means for the user to create an Account on the phone which will eventually sync to their contacts via the app. I'm working in the emulator right now, so I'm going Menu-Dev Tools-AccountsTester to test what I have. When I click on AccountsTester, I get the following error code in LogCat:</p> <pre><code>03-08 18:58:31.996: ERROR/AndroidRuntime(403): java.lang.RuntimeException: Unable to start activity ComponentInfo{com.android.development/com.android.development.AccountsTester}: android.content.res.Resources$NotFoundException: String resource ID #0x0 03-08 18:58:31.996: ERROR/AndroidRuntime(403): at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:1622) 03-08 18:58:31.996: ERROR/AndroidRuntime(403): at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:1638) 03-08 18:58:31.996: ERROR/AndroidRuntime(403): at android.app.ActivityThread.access$1500(ActivityThread.java:117) 03-08 18:58:31.996: ERROR/AndroidRuntime(403): at android.app.ActivityThread$H.handleMessage(ActivityThread.java:928) 03-08 18:58:31.996: ERROR/AndroidRuntime(403): at android.os.Handler.dispatchMessage(Handler.java:99) 03-08 18:58:31.996: ERROR/AndroidRuntime(403): at android.os.Looper.loop(Looper.java:123) 03-08 18:58:31.996: ERROR/AndroidRuntime(403): at android.app.ActivityThread.main(ActivityThread.java:3647) 03-08 18:58:31.996: ERROR/AndroidRuntime(403): at java.lang.reflect.Method.invokeNative(Native Method) 03-08 18:58:31.996: ERROR/AndroidRuntime(403): at java.lang.reflect.Method.invoke(Method.java:507) 03-08 18:58:31.996: ERROR/AndroidRuntime(403): at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:839) 03-08 18:58:31.996: ERROR/AndroidRuntime(403): at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:597) 03-08 18:58:31.996: ERROR/AndroidRuntime(403): at dalvik.system.NativeStart.main(Native Method) 03-08 18:58:31.996: ERROR/AndroidRuntime(403): Caused by: android.content.res.Resources$NotFoundException: String resource ID #0x0 03-08 18:58:31.996: ERROR/AndroidRuntime(403): at android.content.res.Resources.getText(Resources.java:201) 03-08 18:58:31.996: ERROR/AndroidRuntime(403): at android.content.res.Resources.getString(Resources.java:254) 03-08 18:58:31.996: ERROR/AndroidRuntime(403): at android.content.Context.getString(Context.java:183) 03-08 18:58:31.996: ERROR/AndroidRuntime(403): at com.android.development.AccountsTester.initializeAuthenticatorsSpinner(AccountsTester.java:147) 03-08 18:58:31.996: ERROR/AndroidRuntime(403): at com.android.development.AccountsTester.onCreate(AccountsTester.java:63) 03-08 18:58:31.996: ERROR/AndroidRuntime(403): at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1047) 03-08 18:58:31.996: ERROR/AndroidRuntime(403): at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:1586) 03-08 18:58:31.996: ERROR/AndroidRuntime(403): ... 11 more </code></pre> <p>As you can see there is no @ line showing where the error is occurring in my code. I google searched a few of the standout lines but couldn't find anything in relation to my problem. Does anyone have an idea of what is going on here? Please let me know if there is any info you could use to help answer which I didn't include... thanks!</p> <p>The layout which AccountsTester would call:</p> <pre><code>&lt;?xml version="1.0" encoding="utf-8"?&gt; &lt;LinearLayout xmlns:android="http://schemas.android.com/apk/res/android" android:layout_width="fill_parent" android:layout_height="wrap_content" android:orientation="vertical"&gt; &lt;ScrollView android:layout_width="fill_parent" android:layout_height="wrap_content" android:layout_weight="1"&gt; &lt;LinearLayout android:layout_width="fill_parent" android:layout_height="wrap_content" android:layout_weight="1" android:orientation="vertical" android:paddingTop="5dip" android:paddingLeft="20dip" android:paddingRight="20dip" android:paddingBottom="13dip"&gt; &lt;TextView android:id="@+id/account_login_message" android:textAppearance="?android:attr/textAppearanceSmall" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_marginBottom="5dip"/&gt; &lt;TextView android:textAppearance="?android:attr/textAppearanceSmall" android:textStyle="bold" android:layout_width="wrap_content" android:layout_height="wrap_content" android:text="Username"/&gt; &lt;EditText android:id="@+id/account_login_username_edittext" android:singleLine="true" android:layout_width="fill_parent" android:layout_height="wrap_content" android:minWidth="250dip" android:scrollHorizontally="true" android:capitalize="none" android:autoText="false" android:inputType="text"/&gt; &lt;TextView android:id="@+id/account_login_username_fixed" android:textAppearance="?android:attr/textAppearanceSmall" android:singleLine="true" android:layout_marginTop="2dip" android:layout_width="wrap_content" android:layout_height="wrap_content"/&gt; &lt;TextView android:textAppearance="?android:attr/textAppearanceSmall" android:textStyle="bold" android:singleLine="true" android:layout_marginTop="2dip" android:layout_width="wrap_content" android:layout_height="wrap_content" android:text="Password"/&gt; &lt;EditText android:id="@+id/account_login_password_edittext" android:singleLine="true" android:layout_width="fill_parent" android:layout_height="wrap_content" android:minWidth="250dip" android:scrollHorizontally="true" android:capitalize="none" android:autoText="false" android:inputType="textPassword"/&gt; &lt;TextView android:id="@+id/account_login_message_bottom" android:textAppearance="?android:attr/textAppearanceSmall" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_marginBottom="5dip"/&gt; &lt;/LinearLayout&gt; &lt;/ScrollView&gt; &lt;FrameLayout android:layout_width="fill_parent" android:layout_height="wrap_content" android:layout_weight="1" android:background="#c6c3c6" android:minHeight="54dip" android:paddingLeft="2dip" android:paddingTop="4dip" android:paddingRight="2dip"&gt; &lt;Button android:id="@+id/account_login_ok_button" android:layout_height="wrap_content" android:layout_width="wrap_content" android:layout_gravity="center_horizontal" android:minWidth="100dip" android:text="Sign In" android:onClick="handleLogin"/&gt; &lt;/FrameLayout&gt; &lt;/LinearLayout&gt; </code></pre> <p>I don't call a single string there... My activity references strings a few times, but the strings it references are most certainly there, I'm seeing them as I type this, and I'd get an error in Eclipse anyhow.</p>
    singulars
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload