Align Button to the bottom of screen

ShAnE lAwD

New Member
I have two buttons in a frame layout and want them to align at the bottom of screen one below the another.Using \[code\]android:layout_gravity="bottom"\[/code\] makes them overlap over each other. I have no issues doing it with Relativelayout but relativelayout doesn't supports \[code\]android:layout_gravity="bottom"\[/code\]My XML Layout file\[code\]<?xml version="1.0" encoding="utf-8"?><FrameLayout xmlns:android="http://schemas.android.com/apk/res/android" android:layout_width="fill_parent" android:layout_height="fill_parent" android:background="@drawable/bg" android:orientation="vertical" > <Button android:layout_width="fill_parent" android:layout_height="wrap_content" android:id="@+id/scanit" android:layout_gravity="bottom" android:text="Button 1" /> <Button android:layout_width="fill_parent" android:layout_height="wrap_content" android:id="@+id/inf" android:layout_gravity="bottom" android:text="Button 2" /></FrameLayout>\[/code\]
 
Back
Top