I am new to android.Wen I run this apk file in my phone,it runs and wen I rotate for a horizontal view,it shows only half a page and if I try to scroll,it doesnt scroll.I tried a lot using ScrollView.It is not getting Implemented.the error wch occurs is :"activity_main.xml: ScrollView can host only one direct child".Can someone suggest me how to solve it??
<RelativeLayout 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:paddingBottom="@dimen/activity_vertical_margin"
android:paddingLeft="@dimen/activity_horizontal_margin"
android:paddingRight="@dimen/activity_horizontal_margin"
android:paddingTop="@dimen/activity_vertical_margin"
tools:context=".MainActivity" >
<TextView
android:id="@+id/textView1"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_alignBottom="@+id/imageView1"
android:layout_centerHorizontal="true"
android:text="LOGIN"
android:textSize="30sp"
android:textStyle="bold" />
<TextView
android:id="@+id/textView1"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_alignParentLeft="true"
android:layout_below="@+id/imageView1"
android:layout_marginTop="49dp"
android:text="Username"
android:textSize="20sp" />
<TextView
android:id="@+id/textView2"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_alignLeft="@+id/textView1"
android:layout_below="@+id/editText3"
android:layout_marginTop="17dp"
android:text="Password"
android:textSize="20sp" />
<TextView
android:id="@+id/link_to_register"
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:layout_alignRight="@+id/button1"
android:layout_below="@+id/button1"
android:layout_marginTop="14dp"
android:gravity="center"
android:text="Forgot Password"
android:textColor="#0b84aa"
android:textSize="20dip" />
<EditText
android:id="@+id/editText1"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_below="@+id/textView1"
android:layout_marginTop="26dp"
android:layout_toLeftOf="@+id/textView1"
android:ems="10" >
<requestFocus />
</EditText>
<EditText
android:id="@+id/editText3"
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:layout_alignBottom="@+id/textView1"
android:layout_alignLeft="@+id/editText4"
android:ems="10"
android:inputType="textEmailAddress" />
<EditText
android:id="@+id/editText2"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_below="@+id/textView1"
android:layout_marginTop="42dp"
android:layout_toLeftOf="@+id/textView1"
android:ems="10" />
<EditText
android:id="@+id/editText4"
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:layout_alignBaseline="@+id/textView2"
android:layout_alignBottom="@+id/textView2"
android:layout_alignParentRight="true"
android:layout_marginLeft="100dp"
android:ems="10"
android:inputType="textPassword" />
<Button
android:id="@+id/button1"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_alignLeft="@+id/editText3"
android:layout_below="@+id/editText4"
android:layout_marginTop="23dp"
android:background="#9ACD32"
android:text="Log In" />
<ImageView
android:id="@+id/imageView1"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_alignRight="@+id/textView1"
android:layout_below="@+id/imageView2"
android:scaleX="1.5"
android:scaleY="1.5"
android:src="@drawable/igs_login" />
<ImageView
android:id="@+id/imageView2"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_alignParentTop="true"
android:layout_marginTop="21dp"
android:layout_toRightOf="@+id/button1"
android:src="@drawable/igs" />