You can put the button in the activity_layout.xml . For example, if "Activity_Setup.java" is your setup activity, "activity_setup.xml" is its layout, and "myprefs.xml" is the file where your preference layout is stored, then
your should put the button in "activity_setup.xml" under the list, most preferable in a TableRow, like this:
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="match_parent"
android:layout_height="fill_parent"
android:orientation="vertical"
android:id="@+id/llprefs">
<ListView
android:id="@+id/android:list"
android:tag="lvprefs"
android:layout_width="match_parent"
android:layout_height="0.0dp"
android:layout_weight="1" >
</ListView>
<TableRow
android:id="@+id/tableRow1"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginTop="20dp"
>
<Button
android:id="@+id/btRegister"
android:layout_width="wrap_content"
android:layout_height="fill_parent"
android:layout_weight="1"
android:text="@string/IdonothaveA"
android:onClick="onClick"
/>
<Button
android:id="@+id/btForgot"
android:layout_width="wrap_content"
android:layout_height="fill_parent"
android:layout_weight="1"
android:text="@string/Iforgot"
android:onClick="onClick" />
<!--
<Button
android:id="@+id/btContact"
android:layout_width="wrap_content"
android:layout_height="fill_parent"
android:layout_weight="1"
android:text="@string/Contact"
android:onClick="onClick" />
-->
</TableRow>