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 Improving Our Code Simple Refactoring: Creating a New Class

#ben deitch I need some help with your fun facts app how to add scrollView without disrupting the codes for long facts

Android simple app #ben deitch

1 Answer

faraz
PLUS
faraz
Courses Plus Student 21,474 Points

Hey Saivo,

I would love to help you. Please explain the issue you're having so I can better understand.

Faraz

<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android" xmlns:app="http://schemas.android.com/apk/res-auto" xmlns:tools="http://schemas.android.com/tools" android:layout_width="match_parent" android:layout_height="match_parent" android:paddingBottom="50dp" android:paddingLeft="@dimen/activity_horizontal_margin" android:paddingRight="@dimen/activity_horizontal_margin" android:paddingTop="@dimen/activity_vertical_margin" app:layout_behavior="@string/appbar_scrolling_view_behavior" tools:context="mendesapps.Activity" tools:showIn="@layout/activity_Fun_Facts" android:background="#51b46d">

<TextView
    android:layout_width="wrap_content"
    android:layout_height="wrap_content"
    android:text="Fun Facts"
    android:textSize="24sp"
    android:textColor="#80ffffff" />

<TextView
    android:layout_width="wrap_content"
    android:layout_height="wrap_content"
    android:text="Do you know."
    android:id="@+id/reminderTextView"
    android:layout_centerVertical="true"
    android:layout_alignParentLeft="true"
    android:layout_alignParentStart="true"
    android:textSize="24sp"
    android:textColor="@android:color/white" />

<Button
    android:layout_width="match_parent"
    android:layout_height="wrap_content"
    android:text="AnotherFact"
    android:id="@+id/showButton"
    android:layout_alignParentBottom="true"
    android:layout_centerHorizontal="true"
    android:layout_marginBottom="51dp"
    android:background="@android:color/white" />

</RelativeLayout>

thanks bro as you can see this is my layout structure I would like to add scollView to it so that if my fact is longer I can scroll down

can you help me with that ?

faraz
faraz
Courses Plus Student 21,474 Points

Please either push your entire project code to GitHub and send me the link to your repo or zip it up and provide a link for me to download it. After checking out your entire project I'd be able to help. Thanks!

Faraz