Welcome to the Treehouse Community

Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community! While you're at it, check out some resources Treehouse students have shared here.

Looking to learn something new?

Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.

Start your free trial

Android

Handling Errors Using Dialogs - "Hello world!" instead of real message displayed

Here's the content from the strings.xml bellow. "error_title" and "error_message" should be used when displaying the message. I'm not sure why "Hello world!" appears instead,

<?xml version="1.0" encoding="utf-8"?>
<resources>

    <string name="error_title">Oops!Sorry!</string>
    <string name="error_message">There was an error getting data from the blog.</string>
    <string name="app_name">BlogReader</string>
    <string name="action_settings">Settings</string>
    <string name="no_items">No items to display!</string>




    <string-array name="android_names">
            <item>"Android beta"</item>
            <item>"Android 1.0"</item>
            <item>"Android 1.1"</item>
            <item>"Cupcake"</item>
            <item>"Donut"</item>
            <item>"Eclair"</item>
            <item>"Froyo"</item>
            <item>"Gingerbread"</item>
            <item>"Honeycomb"</item>
            <item>"Ice Cream Sandwich"</item>
            <item>"Jelly Bean"</item>
    </string-array>


</resources>

1 Answer

Can you please post your java code? Thanks!

Thanks for your reply, it no longer reproduces. However, this is a general issue that I keep having. After I make a change to the code, then I run the application in the emulator, the recent changes don't apply. Using Force Start does not seem to have any effect. I close the emulator, sometimes close Eclipse, then start the application in the emulator a couple of times, and eventually the changes apply.

Is there something in the application/emulator cache that can cause this?