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 Build a Simple Android App Creating the Screen Layout Setting Colors

how can i resolve this challenge and proceed

<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android" android:layout_width="match_parent" android:layout_height="match_parent" android:background="@android:color/white" >

<TextView android:id="@+id/textView1" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_centerHorizontal="true" android:layout_centerVertical="true" android:text="Treehouse loves me!" android:textSize="72sp" />

</RelativeLayout>

activity_main.xml
<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
  android:layout_width="match_parent"
  android:layout_height="match_parent"
  android:background="@android:color/white" >

  <TextView
    android:id="@+id/textView1"
    android:layout_width="wrap_content"
    android:layout_height="wrap_content"
    android:layout_centerHorizontal="true"
    android:layout_centerVertical="true"
    android:text="Treehouse loves me!"
    android:textSize="72sp" />

</RelativeLayout>how do i resolve this challenge and proceed

4 Answers

Jennifer Nordell
seal-mask
STAFF
.a{fill-rule:evenodd;}techdegree
Jennifer Nordell
Treehouse Teacher

I wish I knew what you'd tried that was failing, that way I could be more specific about what's going wrong. Also, I'm not sure which step you're stuck on, but your current code won't pass either. For step 1 you need to have this line in your TextView:

    android:textColor="@android:color/white" 

And for step 2 you need to add this to the RelativeLayout just above the TextView:

  android:background="#fff092b0"

Hope this helps!

please try and help me because i added this android:textColor="@android:color/white" but is not still working, it shows burmer and i cannot attempt another step.

Jennifer Nordell
seal-mask
.a{fill-rule:evenodd;}techdegree
Jennifer Nordell
Treehouse Teacher

This is my ending code that passes both steps. I'm not sure why you're getting an error.

<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
  android:layout_width="match_parent"
  android:layout_height="match_parent"
  android:background="#fff092b0" >

  <TextView
    android:id="@+id/textView1"
    android:layout_width="wrap_content"
    android:layout_height="wrap_content"
    android:layout_centerHorizontal="true"
    android:layout_centerVertical="true"
    android:text="Treehouse loves me!"
    android:textSize="72sp"
    android:textColor="@android:color/white"
    />

</RelativeLayout>

jenny, i really appreciate your effort, please where can i channel this challenge to help move ahead, i have done the above, all the same bummer i am stuck on, jenny try and help

Jennifer Nordell
seal-mask
.a{fill-rule:evenodd;}techdegree
Jennifer Nordell
Treehouse Teacher

I am trying to help. And I*m a little curious as to if it can be a problem in your browser. What happens if you try the above code in the same challenge, but from another browser?

i am using FIREFOX could that be a result of my errors, please which reliable one are u using,i need your recommendation

Jennifer Nordell
seal-mask
.a{fill-rule:evenodd;}techdegree
Jennifer Nordell
Treehouse Teacher

I love Firefox! And it is a super-reliable browser. I'm suspicious that there might be something with the cached data in the browser which you can try clearing and then run the challenge again.

I tend to use Chrome when using Treehouse simply because there are courses later that are specifically geared around the developer tools in Chrome. Firefox itself has great developer tools and if you haven't already gotten it... go get the firebug plugin for Firefox. It'll be your best friend if you ever do any JavaScript and front-end development later.

But back to your problem: I'd say this. Try that code in any other browser right now and see if it passes. If it doesn't, you need to contact Treehouse support, because that is the solution.

jenny your the best ever in treehouse, i also have this challenge, Initialize a new Random variable called randomGenerator. Hint: Don't forget to use the new keyword.