0
I have a screen where it has a title, a table and two buttons at the bottom of the table. I put the table inside a scrollView. However, when the table is filling with lines, it will take the place of the buttons until it disappears. Does anyone know how to solve this? I thank you in advance. Follow an example of my structure:
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:orientation="vertical" >
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_gravity="center" />
<ScrollView
android:layout_width="match_parent"
android:layout_height="match_parent" >
<TableLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:stretchColumns="*" >
</TableLayout>
</ScrollView>
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:orientation="horizontal" >
<Button
android:layout_width="match_parent"
android:layout_height="match_parent"
android:layout_weight="1" />
<Button
android:layout_width="match_parent"
android:layout_height="match_parent"
android:layout_weight="1" />
</LinearLayout>
</LinearLayout>
give a
android:id
to theLinearLayout
where there are two buttons. In your<ScrollView>
, adicone:android:above:+id/idQueVoceAtribuiuAoLayoutDosBotoes
– Marllon Nasser
@Marllonnasser
above
is an attribute of Relativelayout what is being used is a Linearlayout– ramaral
And why not use
RelativeLayout
?– Marllon Nasser
I put the id on all, just took to show here to get cleaner.
– daniel12345smith