android - scroll bar doesn't scroll to the last view -


i have problem scroll view

i have tow toolbar 1 on top , 1 on bottom, , these tool bars should on top of other views

when scroll down last view behind bottom bar , not shown

this pic show mean :

https://drive.google.com/file/d/0b4lj_q-ecia7n19meujuothwanm/view?usp=sharing

in red circle there view behind bar want view shown in same time bottom bar still on top of other views

this layout code :

<relativelayout xmlns:android="http://schemas.android.com/apk/res/android" xmlns:tools="http://schemas.android.com/tools" android:id="@+id/mainroot" android:layout_width="match_parent" android:layout_height="match_parent" tools:context="com.wujhaat.wujhaatod.mainactivity">  <include     android:id="@+id/app_bar"     layout="@layout/app_bar" />  <include     android:id="@+id/end_bar"     layout="@layout/end_bar"     android:layout_width="wrap_content"     android:layout_height="wrap_content"     android:layout_alignparentbottom="true" />  <scrollview xmlns:android="http://schemas.android.com/apk/res/android"     android:id="@+id/scrollview1"     android:layout_width="match_parent"     android:layout_height="match_parent">      <relativelayout xmlns:android="http://schemas.android.com/apk/res/android"         xmlns:tools="http://schemas.android.com/tools"         android:id="@+id/subroot"         android:layout_width="wrap_content"         android:layout_height="wrap_content"         tools:context="com.wujhaat.wujhaatod.mainactivity">          <textview             android:id="@+id/basic_info"             android:layout_width="wrap_content"             android:layout_height="72dp"             android:layout_margintop="50dp"             android:layout_marginleft="72dp"             android:layout_marginright="72dp"             android:gravity="center"             android:text="@string/title_activity_main"             android:textcolor="@color/primarycolor"             android:textsize="24sp"             android:typeface="sans" />          <textview             android:id="@+id/nametv"             android:layout_width="wrap_content"             android:layout_height="wrap_content"             android:layout_below="@+id/basic_info"             android:layout_marginleft="72dp"             android:layout_marginright="72dp"             android:text="@string/name"             android:textsize="16sp"             android:typeface="sans" />          <edittext             android:id="@+id/name"             android:layout_width="match_parent"             android:layout_height="wrap_content"             android:layout_below="@+id/nametv"             android:layout_marginbottom="8dp"             android:layout_marginend="16dp"             android:layout_marginleft="72dp"             android:layout_marginright="16dp"             android:layout_marginstart="72dp" />          <textview             android:id="@+id/emailtv"             android:layout_width="wrap_content"             android:layout_height="wrap_content"             android:layout_below="@+id/name"             android:layout_marginleft="72dp"             android:layout_marginright="72dp"             android:text="@string/email"             android:textsize="16sp"             android:typeface="sans" />          <edittext             android:id="@+id/email"             android:layout_width="match_parent"             android:layout_height="wrap_content"             android:layout_below="@+id/emailtv"             android:layout_marginbottom="8dp"             android:layout_marginend="16dp"             android:layout_marginleft="72dp"             android:layout_marginright="16dp"             android:layout_marginstart="72dp"             android:hint="@string/email_hint"             android:inputtype="textemailaddress" />          <textview             android:id="@+id/mobiletv"             android:layout_width="wrap_content"             android:layout_height="wrap_content"             android:layout_below="@+id/email"             android:layout_marginleft="72dp"             android:layout_marginright="72dp"             android:text="@string/mobile"             android:textsize="16sp"             android:typeface="sans" />          <edittext             android:id="@+id/mobile"             android:layout_width="match_parent"             android:layout_height="wrap_content"             android:layout_below="@+id/mobiletv"             android:layout_marginbottom="8dp"             android:layout_marginend="16dp"             android:layout_marginleft="72dp"             android:layout_marginright="16dp"             android:layout_marginstart="72dp"             android:hint="0512345678"             android:inputtype="number"             android:maxlength="10" />          <textview             android:id="@+id/adultnotv"             android:layout_width="wrap_content"             android:layout_height="wrap_content"             android:layout_below="@+id/mobile"             android:layout_marginleft="72dp"             android:layout_marginright="72dp"             android:text="@string/adult_no"             android:textsize="16sp"             android:typeface="sans" />          <spinner             android:id="@+id/adult_spinner"             android:layout_width="match_parent"             android:layout_height="wrap_content"             android:layout_below="@+id/adultnotv"             android:layout_marginbottom="8dp"             android:layout_marginend="16dp"             android:layout_marginleft="72dp"             android:layout_marginright="16dp"             android:layout_marginstart="72dp"             android:entries="@array/traveler_no_spinner" />          <textview             android:id="@+id/childnotv"             android:layout_width="wrap_content"             android:layout_height="wrap_content"             android:layout_below="@+id/adult_spinner"             android:layout_marginleft="72dp"             android:layout_marginright="72dp"             android:text="@string/child_no"             android:textsize="16sp"             android:typeface="sans" />          <spinner             android:id="@+id/child_spinner"             android:layout_width="match_parent"             android:layout_height="wrap_content"             android:layout_below="@+id/childnotv"             android:layout_marginbottom="8dp"             android:layout_marginend="16dp"             android:layout_marginleft="72dp"             android:layout_marginright="16dp"             android:layout_marginstart="72dp"             android:entries="@array/traveler_no_spinner" />          <textview             android:id="@+id/infanttv"             android:layout_width="wrap_content"             android:layout_height="wrap_content"             android:layout_below="@+id/child_spinner"             android:layout_marginleft="72dp"             android:layout_marginright="72dp"             android:text="@string/infant_no"             android:textsize="16sp"             android:typeface="sans" />          <spinner             android:id="@+id/infant_spinner"             android:layout_width="match_parent"             android:layout_height="wrap_content"             android:layout_below="@+id/infanttv"             android:layout_marginbottom="8dp"             android:layout_marginend="16dp"             android:layout_marginleft="72dp"             android:layout_marginright="16dp"             android:layout_marginstart="72dp"             android:entries="@array/traveler_no_spinner" />          <textview             android:id="@+id/visatv"             android:layout_width="wrap_content"             android:layout_height="wrap_content"             android:layout_below="@+id/infant_spinner"             android:layout_marginleft="72dp"             android:layout_marginright="72dp"             android:text="@string/visa"             android:textsize="16sp"             android:typeface="sans" />          <spinner             android:id="@+id/visa_spinner"             android:layout_width="match_parent"             android:layout_height="wrap_content"             android:layout_below="@+id/visatv"             android:layout_marginbottom="8dp"             android:layout_marginend="16dp"             android:layout_marginleft="72dp"             android:layout_marginright="16dp"             android:layout_marginstart="72dp"             android:entries="@array/yes_no" />          <textview             android:id="@+id/visatv1"             android:layout_width="wrap_content"             android:layout_height="wrap_content"             android:layout_below="@+id/visa_spinner"             android:layout_marginleft="72dp"             android:layout_marginright="72dp"             android:text="@string/visa"             android:textsize="16sp"             android:typeface="sans" />          <spinner             android:id="@+id/visa_spinner1"             android:layout_width="match_parent"             android:layout_height="wrap_content"             android:layout_below="@+id/visatv1"             android:layout_marginbottom="8dp"             android:layout_marginend="16dp"             android:layout_marginleft="72dp"             android:layout_marginright="16dp"             android:layout_marginstart="72dp"             android:entries="@array/yes_no" />          <textview             android:id="@+id/visatv2"             android:layout_width="wrap_content"             android:layout_height="wrap_content"             android:layout_below="@+id/visa_spinner1"             android:layout_marginleft="72dp"             android:layout_marginright="72dp"             android:text="@string/visa"             android:textsize="16sp"             android:typeface="sans" />          <spinner             android:id="@+id/visa_spinner2"             android:layout_width="match_parent"             android:layout_height="wrap_content"             android:layout_below="@+id/visatv2"             android:layout_marginbottom="8dp"             android:layout_marginend="16dp"             android:layout_marginleft="72dp"             android:layout_marginright="16dp"             android:layout_marginstart="72dp"             android:entries="@array/yes_no" />      </relativelayout> </scrollview>  </relativelayout> 

please need help???

try adding following scrollview xml

android:layout_above="@id/end_bar" 

this set scrollview appear relative toolbars, fitting in space between them, instead of placing them on top of scrollview

you may need add android:layout_below="@id/app_bar" if it's appearing underneath top toolbar.


Comments

Popular posts from this blog

javascript - gulp-nodemon - nodejs restart after file change - Error: listen EADDRINUSE events.js:85 -

Fatal Python error: Py_Initialize: unable to load the file system codec. ImportError: No module named 'encodings' -

javascript - oscilloscope of speaker input stops rendering after a few seconds -