I have created an activity in which there is four button in center . i want that when i click on any of button then there should be open another Xml file in same. i don't want to move on another activity . i want to show on same Activity with new Xml. This new Xml hide previous one.
first xml is:-
<include
android:id="@+id/header"
layout="@layout/header"
android:layout_alignParentTop="true">
</include>
<Button
style="@style/homePageBtnStyle"
android:id="@+id/howToUse"
android:layout_centerHorizontal="true"
android:layout_marginTop="110dp"
android:text="@string/howToUse"
/>
<Button
style="@style/homePageBtnStyle"
android:id="@+id/purposeOfApp"
android:layout_alignLeft="@+id/howToUse"
android:layout_marginTop="10dp"
android:text="@string/purposeOfApp"
android:layout_below="@+id/howToUse"
/>
<Button
style="@style/homePageBtnStyle"
android:id="@+id/rateThisApp"
android:layout_alignLeft="@+id/purposeOfApp"
android:layout_marginTop="10dp"
android:text="@string/rateThisApp"
android:layout_below="@+id/purposeOfApp"
/>
and second xml is:-
<TextView xmlns:android="http://schemas.android.com/apk/res/android"
android:text="@string/howtousetext"
android:id="@+id/textInstruction"
android:textColor="@color/btn_border"
android:layout_width="fill_parent"
android:layout_height="fill_parent"
android:
android:background="@color/themeColor"
/>