I have created an app where i showing listview with an image and text . I add Button in the end of page . But this is not showing on screen .I am new in android .How can i
Put into RelativeLayout
parrent then set a static marginBottom
that is equal to height of the button for listview and after that put the button in bottom of the parrent
Set android:layout_height="0dip"
and android:layout_weight="1"
to ListView
as below...
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:tools="http://schemas.android.com/tools"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:background="@drawable/maps"
android:orientation="vertical"
android:padding="8dp"
tools:context=".MainActivity" >
<TextView
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:gravity="center"
android:text="@string/WAYLF"
android:textSize="22sp" />
<ListView
android:id="@+id/list_view"
android:layout_width="match_parent"
android:layout_height="0dip"
android:layout_weight="1"
android:cacheColorHint="@android:color/transparent"
android:dividerHeight="4dp" />
<Button
android:layout_width="match_parent"
android:layout_height="35dp"
android:layout_marginTop="25dp"
android:background="@android:color/holo_green_light"
android:text="@string/NEXT" />
</LinearLayout>