2

I have an activity that has a ScrollView, and for some reason when the activity loads, it does not start from the top but somewhere in the middle. I tried to work this out in the code but that was unsuccessful. I even tried in the XML by adding

android:windowSoftInputMode="stateHidden" 

Since I have quite a few EditText in that Acitivity, but all attempts have been unsuccessful.

Below is the layout code:

Any help would be greatly appreciated Update: <ScrollView xmlns:android="http://schemas.android.com/apk/res/android" android:id="@+id/scrollProfile" android:layout_width="match_parent" android:layout_height="match_parent" android:alpha="0.9" android:background="#ffffff" > <RelativeLayout android:id="@+id/main" android:layout_width="match_parent" android:layout_height="797dp" android:descendantFocusability="beforeDescendants" > <TextView android:id="@+id/tASearchDistance" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_centerHorizontal="true" android:layout_marginTop="39dp" android:gravity="left" android:text="Profile Creation" android:textColor="#ffffff" android:textSize="28sp" android:textStyle="bold" android:typeface="sans" /> <TextView android:id="@+id/tSex" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_below="@+id/etxtname" android:layout_centerHorizontal="true" android:layout_marginTop="15dp" android:text="Upload your Profile Picture" android:textColor="#f2f2f2" android:textSize="18sp" android:textStyle="bold" android:typeface="sans" /> <RadioGroup android:id="@+id/radioGroup1" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_alignLeft="@+id/etxtheadline" android:layout_below="@+id/texperience" > <RadioButton android:id="@+id/rimale" android:layout_width="wrap_content" android:layout_height="wrap_content" android:checked="true" android:text="Male" android:textColor="#000" /> <RadioButton android:id="@+id/rifemale" android:layout_width="wrap_content" android:layout_height="wrap_content" android:text="Female" android:textColor="#000" /> </RadioGroup> <SeekBar android:id="@+id/sbseekBarDistance" android:layout_width="250dp" android:layout_height="wrap_content" android:layout_below="@+id/textView12" android:layout_centerHorizontal="true" android:layout_marginTop="11dp" android:progress="50" /> <RadioGroup android:id="@+id/radioGroup3" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_alignLeft="@+id/tAge" android:layout_below="@+id/tAge" > <RadioButton android:id="@+id/rlmale" android:layout_width="wrap_content" android:layout_height="wrap_content" android:checked="true" android:text="Male" android:textColor="#000" /> <RadioButton android:id="@+id/rlfemale" android:layout_width="wrap_content" android:layout_height="wrap_content" android:text="Female" android:textColor="#000" /> </RadioGroup> <SeekBar android:id="@+id/sbseekBarMinimumAge" android:layout_width="250dp" android:layout_height="wrap_content" android:layout_below="@+id/tName4" android:layout_centerHorizontal="true" android:layout_marginTop="11dp" android:progress="25" /> <TextView android:id="@+id/tvseekBarDistanceValue" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_alignRight="@+id/tvMinAge" android:layout_below="@+id/sbseekBarDistance" android:text="50" android:textAppearance="?android:attr/textAppearanceMedium" android:textColor="#000" android:textSize="18sp" android:typeface="serif" /> <TextView android:id="@+id/textView12" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_below="@+id/radioGroup1" android:layout_centerHorizontal="true" android:layout_marginTop="19dp" android:text="Individual search distance " android:textAppearance="?android:attr/textAppearanceMedium" android:textColor="#3D3C3A" android:textSize="18sp" android:textStyle="bold" android:typeface="sans" /> <SeekBar android:id="@+id/sbseekBarMaximumAge" android:layout_width="250dp" android:layout_height="wrap_content" android:layout_below="@+id/textView14" android:layout_centerHorizontal="true" android:layout_marginTop="11dp" android:progress="50" /> <TextView android:id="@+id/conditions" android:layout_width="280dp" android:layout_height="130dp" android:layout_below="@+id/btnConfirm" android:layout_centerHorizontal="true" android:layout_marginBottom="7dp" android:layout_marginTop="7dp" android:alpha="0.5" android:gravity="center" android:text="@string/disclaimer" android:textColor="#000" android:textSize="12sp" android:typeface="sans" /> <TextView android:id="@+id/tAge" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_above="@+id/radioGroup1" android:layout_alignRight="@+id/btnConfirm" android:text="Looking for" android:textColor="#3D3C3A" android:textColorHint="#3D3C3A" android:textSize="18sp" android:textStyle="bold" /> <TextView android:id="@+id/texperience" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_alignLeft="@+id/radioGroup1" android:layout_below="@+id/etxtheadline" android:layout_marginTop="39dp" android:text="I am a" android:textColor="#3D3C3A" android:textSize="18sp" android:textStyle="bold" /> <SeekBar android:id="@+id/sbseekBarActivityDistance" android:layout_width="250dp" android:layout_height="wrap_content" android:layout_alignRight="@+id/sbseekBarDistance" android:layout_below="@+id/tName01" android:progress="50" /> <TextView android:id="@+id/tvseekBarActivityDistanceValue" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_alignLeft="@+id/tvseekBarDistanceValue" android:layout_below="@+id/sbseekBarActivityDistance" android:text="50" android:textSize="18sp" /> <TextView android:id="@+id/tName01" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_below="@+id/tvseekBarDistanceValue" android:layout_centerHorizontal="true" android:layout_marginTop="14dp" android:text="Activities search distance" android:textSize="18sp" android:textStyle="bold" android:typeface="sans" /> <TextView android:id="@+id/textView14" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_alignLeft="@+id/tName4" android:layout_below="@+id/tvMinAge" android:layout_marginTop="16dp" android:text="Maximum Age Looking For" android:textColor="#3D3C3A" android:textSize="18sp" android:textStyle="bold" android:typeface="sans" /> <EditText android:id="@+id/etxtheadline" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_alignLeft="@+id/sbseekBarMaximumAge" android:layout_alignRight="@+id/conditions" android:layout_below="@+id/tvMaxAge" android:ems="10" android:gravity="left" android:hint="Quick description about you" android:maxLength="50" android:singleLine="true" android:textAlignment="gravity" android:textColor="#000" android:textColorHint="#3D3C3A" android:textSize="17sp" android:typeface="serif" /> <Button android:id="@+id/btnConfirm" android:layout_width="120dp" android:layout_height="60dp" android:layout_alignBaseline="@+id/btnBack" android:layout_alignBottom="@+id/btnBack" android:layout_alignRight="@+id/tvPaid4" android:alpha="0.8" android:background="@drawable/blue_bac2" android:text="Confirm" android:textColor="#ffffff" android:textSize="17sp" android:textStyle="bold" /> <TextView android:id="@+id/tName4" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_alignLeft="@+id/tName01" android:layout_below="@+id/etxtage" android:layout_marginTop="18dp" android:text="Minimum Age Looking For" android:textColor="#3D3C3A" android:textSize="18sp" android:textStyle="bold" android:typeface="sans" /> <TextView android:id="@+id/tvMinAge" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_below="@+id/sbseekBarMinimumAge" android:layout_centerHorizontal="true" android:text="25" android:textColor="#000" android:textSize="18sp" android:typeface="sans" /> <TextView android:id="@+id/tvMaxAge" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_below="@+id/sbseekBarMaximumAge" android:layout_centerHorizontal="true" android:text="50" android:textColor="#000" android:textSize="18sp" android:typeface="sans" /> <TextView android:id="@+id/tProfileTitle" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_alignParentLeft="true" android:layout_alignParentTop="true" android:layout_marginTop="12dp" android:padding="10dp" android:text="Welcome to Dooba. We provide you with a date for everything you want to do. To begin, please fill out all of the information below." android:textSize="20sp" android:textStyle="normal|bold" android:typeface="sans" /> <Button android:id="@+id/btnPictureSelect" android:layout_width="130dp" android:layout_height="60dp" android:layout_alignRight="@+id/profilePicturePreview" android:layout_below="@+id/profilePicturePreview" android:alpha="0.8" android:background="#3D3C3A" android:gravity="center_vertical|center_horizontal|left" android:onClick="pickPhoto" android:padding="5dp" android:text="Upload from device gallery" android:textColor="#ffffff" android:textSize="18sp" android:textStyle="bold" android:typeface="sans" /> <Button android:id="@+id/btnBack" android:layout_width="120dp" android:layout_height="60dp" android:layout_below="@+id/tvseekBarActivityDistanceValue" android:layout_marginTop="28dp" android:layout_toLeftOf="@+id/tvseekBarActivityDistanceValue" android:alpha="0.8" android:background="#ccc" android:text="Back" android:textColor="#000" android:textSize="17sp" android:textStyle="bold" /> <EditText android:id="@+id/etxtage" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_below="@+id/btnPictureSelect" android:layout_centerHorizontal="true" android:layout_marginTop="29dp" android:ems="10" android:hint="Enter your age here" android:inputType="number" android:maxLength="2" android:textAlignment="center" android:textColor="#000" android:textColorHint="#3D3C3A" android:textSize="17sp" android:typeface="sans" > </EditText> <EditText android:id="@+id/etxtname" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_alignLeft="@+id/conditions" android:layout_alignRight="@+id/sbseekBarMinimumAge" android:layout_below="@+id/tvPaid1" android:layout_marginTop="17dp" android:ems="10" android:gravity="center" android:hint="Enter your name here" android:inputType="textPersonName" android:maxLength="30" android:textColor="#000" android:textColorHint="#3D3C3A" android:textSize="18sp" android:typeface="sans" /> <TextView android:id="@+id/tvPaid1" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_alignLeft="@+id/conditions" android:layout_alignRight="@+id/etxtname" android:layout_below="@+id/tProfileTitle" android:layout_marginTop="19dp" android:gravity="center" android:text="Profile Creation" android:textColor="#ff0000" android:textSize="25sp" android:textStyle="bold|normal" android:typeface="sans" /> <ImageView android:id="@+id/profilePicturePreview" android:layout_width="132dp" android:layout_height="120dp" android:layout_below="@+id/tvPaid4" android:layout_marginTop="14dp" android:layout_toRightOf="@+id/texperience" android:alpha="1" android:background="@drawable/border_image" android:cropToPadding="true" android:padding="3dp" android:scaleType="centerCrop" /> <TextView android:id="@+id/tvPaid4" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_alignLeft="@+id/sbseekBarMinimumAge" android:layout_alignTop="@+id/tSex" android:text="Upload your profile picture" android:textSize="20sp" android:textStyle="bold" android:typeface="sans" /> </RelativeLayout> </ScrollView> 
4
  • Try this in activity: myScrollView.fullScroll(ScrollView.FOCUS_UP); Commented Oct 22, 2014 at 6:38
  • remove android:layout_gravity="top|center" in scrollview and try Commented Oct 22, 2014 at 6:41
  • what these for?!! android:layout_gravity="top|center" android:layout_alignParentTop="true". your scrollview is the root layout. not in relative layout to use layout_alignParentTop and not in frame layout to use layout_gravity Commented Oct 22, 2014 at 7:10
  • thank you much for your response. I still seem to have the same issue. I have updated my code and provide an update under my initial post Commented Oct 22, 2014 at 11:50

2 Answers 2

4

your problem causes by your EditText it has focus so you must remove focus from it;

in onCreate:

RelativeLayout v = (RelativeLayout) findViewById(R.id.main); v.requestFocus(); 

if the above dose not work then for all of your EditText call setFocusable(false);

Update:

public class MainActivity extends Activity { @Override protected void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); setContentView(R.layout.activity_main); ScrollView v = (ScrollView) findViewById(R.id.scrollProfile); v.requestFocus(); } } 

and xml:

<ScrollView xmlns:android="http://schemas.android.com/apk/res/android" android:id="@+id/scrollProfile" android:layout_width="match_parent" android:layout_height="match_parent" android:alpha="0.9" android:background="#ffffff" > <RelativeLayout android:id="@+id/main" android:layout_width="match_parent" android:layout_height="797dp"> <TextView android:id="@+id/tASearchDistance" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_centerHorizontal="true" android:layout_marginTop="39dp" android:gravity="left" android:text="Profile Creation" android:textColor="#ffffff" android:textSize="28sp" android:textStyle="bold" android:typeface="sans" /> <TextView android:id="@+id/tSex" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_below="@+id/etxtname" android:layout_centerHorizontal="true" android:layout_marginTop="15dp" android:text="Upload your Profile Picture" android:textColor="#f2f2f2" android:textSize="18sp" android:textStyle="bold" android:typeface="sans" /> <RadioGroup android:id="@+id/radioGroup1" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_alignLeft="@+id/etxtheadline" android:layout_below="@+id/texperience" > <RadioButton android:id="@+id/rimale" android:layout_width="wrap_content" android:layout_height="wrap_content" android:checked="true" android:text="Male" android:textColor="#000" /> <RadioButton android:id="@+id/rifemale" android:layout_width="wrap_content" android:layout_height="wrap_content" android:text="Female" android:textColor="#000" /> </RadioGroup> <SeekBar android:id="@+id/sbseekBarDistance" android:layout_width="250dp" android:layout_height="wrap_content" android:layout_below="@+id/textView12" android:layout_centerHorizontal="true" android:layout_marginTop="11dp" android:progress="50" /> <RadioGroup android:id="@+id/radioGroup3" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_alignLeft="@+id/tAge" android:layout_below="@+id/tAge" > <RadioButton android:id="@+id/rlmale" android:layout_width="wrap_content" android:layout_height="wrap_content" android:checked="true" android:text="Male" android:textColor="#000" /> <RadioButton android:id="@+id/rlfemale" android:layout_width="wrap_content" android:layout_height="wrap_content" android:text="Female" android:textColor="#000" /> </RadioGroup> <SeekBar android:id="@+id/sbseekBarMinimumAge" android:layout_width="250dp" android:layout_height="wrap_content" android:layout_below="@+id/tName4" android:layout_centerHorizontal="true" android:layout_marginTop="11dp" android:progress="25" /> <TextView android:id="@+id/tvseekBarDistanceValue" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_alignRight="@+id/tvMinAge" android:layout_below="@+id/sbseekBarDistance" android:text="50" android:textAppearance="?android:attr/textAppearanceMedium" android:textColor="#000" android:textSize="18sp" android:typeface="serif" /> <TextView android:id="@+id/textView12" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_below="@+id/radioGroup1" android:layout_centerHorizontal="true" android:layout_marginTop="19dp" android:text="Individual search distance " android:textAppearance="?android:attr/textAppearanceMedium" android:textColor="#3D3C3A" android:textSize="18sp" android:textStyle="bold" android:typeface="sans" /> <SeekBar android:id="@+id/sbseekBarMaximumAge" android:layout_width="250dp" android:layout_height="wrap_content" android:layout_below="@+id/textView14" android:layout_centerHorizontal="true" android:layout_marginTop="11dp" android:progress="50" /> <TextView android:id="@+id/conditions" android:layout_width="280dp" android:layout_height="130dp" android:layout_below="@+id/btnConfirm" android:layout_centerHorizontal="true" android:layout_marginBottom="7dp" android:layout_marginTop="7dp" android:alpha="0.5" android:gravity="center" android:text="Hello" android:textColor="#000" android:textSize="12sp" android:typeface="sans" /> <TextView android:id="@+id/tAge" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_above="@+id/radioGroup1" android:layout_alignRight="@+id/btnConfirm" android:text="Looking for" android:textColor="#3D3C3A" android:textColorHint="#3D3C3A" android:textSize="18sp" android:textStyle="bold" /> <TextView android:id="@+id/texperience" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_alignLeft="@+id/radioGroup1" android:layout_below="@+id/etxtheadline" android:layout_marginTop="39dp" android:text="I am a" android:textColor="#3D3C3A" android:textSize="18sp" android:textStyle="bold" /> <SeekBar android:id="@+id/sbseekBarActivityDistance" android:layout_width="250dp" android:layout_height="wrap_content" android:layout_alignRight="@+id/sbseekBarDistance" android:layout_below="@+id/tName01" android:progress="50" /> <TextView android:id="@+id/tvseekBarActivityDistanceValue" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_alignLeft="@+id/tvseekBarDistanceValue" android:layout_below="@+id/sbseekBarActivityDistance" android:text="50" android:textSize="18sp" /> <TextView android:id="@+id/tName01" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_below="@+id/tvseekBarDistanceValue" android:layout_centerHorizontal="true" android:layout_marginTop="14dp" android:text="Activities search distance" android:textSize="18sp" android:textStyle="bold" android:typeface="sans" /> <TextView android:id="@+id/textView14" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_alignLeft="@+id/tName4" android:layout_below="@+id/tvMinAge" android:layout_marginTop="16dp" android:text="Maximum Age Looking For" android:textColor="#3D3C3A" android:textSize="18sp" android:textStyle="bold" android:typeface="sans" /> <EditText android:id="@+id/etxtheadline" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_alignLeft="@+id/sbseekBarMaximumAge" android:layout_alignRight="@+id/conditions" android:layout_below="@+id/tvMaxAge" android:ems="10" android:gravity="left" android:hint="Quick description about you" android:maxLength="50" android:singleLine="true" android:textAlignment="gravity" android:textColor="#000" android:textColorHint="#3D3C3A" android:textSize="17sp" android:typeface="serif" /> <Button android:id="@+id/btnConfirm" android:layout_width="120dp" android:layout_height="60dp" android:layout_alignBaseline="@+id/btnBack" android:layout_alignBottom="@+id/btnBack" android:layout_alignRight="@+id/tvPaid4" android:alpha="0.8" android:background="#00FFFF" android:text="Confirm" android:textColor="#ffffff" android:textSize="17sp" android:textStyle="bold" /> <TextView android:id="@+id/tName4" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_alignLeft="@+id/tName01" android:layout_below="@+id/etxtage" android:layout_marginTop="18dp" android:text="Minimum Age Looking For" android:textColor="#3D3C3A" android:textSize="18sp" android:textStyle="bold" android:typeface="sans" /> <TextView android:id="@+id/tvMinAge" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_below="@+id/sbseekBarMinimumAge" android:layout_centerHorizontal="true" android:text="25" android:textColor="#000" android:textSize="18sp" android:typeface="sans" /> <TextView android:id="@+id/tvMaxAge" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_below="@+id/sbseekBarMaximumAge" android:layout_centerHorizontal="true" android:text="50" android:textColor="#000" android:textSize="18sp" android:typeface="sans" /> <TextView android:id="@+id/tProfileTitle" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_alignParentLeft="true" android:layout_alignParentTop="true" android:layout_marginTop="12dp" android:padding="10dp" android:text="Welcome to Dooba. We provide you with a date for everything you want to do. To begin, please fill out all of the information below." android:textSize="20sp" android:textStyle="normal|bold" android:typeface="sans" /> <Button android:id="@+id/btnPictureSelect" android:layout_width="130dp" android:layout_height="60dp" android:layout_alignRight="@+id/profilePicturePreview" android:layout_below="@+id/profilePicturePreview" android:alpha="0.8" android:background="#3D3C3A" android:gravity="center_vertical|center_horizontal|left" android:onClick="pickPhoto" android:padding="5dp" android:text="Upload from device gallery" android:textColor="#ffffff" android:textSize="18sp" android:textStyle="bold" android:typeface="sans" /> <Button android:id="@+id/btnBack" android:layout_width="120dp" android:layout_height="60dp" android:layout_below="@+id/tvseekBarActivityDistanceValue" android:layout_marginTop="28dp" android:layout_toLeftOf="@+id/tvseekBarActivityDistanceValue" android:alpha="0.8" android:background="#ccc" android:text="Back" android:textColor="#000" android:textSize="17sp" android:textStyle="bold" /> <EditText android:id="@+id/etxtage" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_below="@+id/btnPictureSelect" android:layout_centerHorizontal="true" android:layout_marginTop="29dp" android:ems="10" android:hint="Enter your age here" android:inputType="number" android:maxLength="2" android:textAlignment="center" android:textColor="#000" android:textColorHint="#3D3C3A" android:textSize="17sp" android:typeface="sans" > </EditText> <EditText android:id="@+id/etxtname" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_alignLeft="@+id/conditions" android:layout_alignRight="@+id/sbseekBarMinimumAge" android:layout_below="@+id/tvPaid1" android:layout_marginTop="17dp" android:ems="10" android:gravity="center" android:hint="Enter your name here" android:inputType="textPersonName" android:maxLength="30" android:textColor="#000" android:textColorHint="#3D3C3A" android:textSize="18sp" android:typeface="sans" /> <TextView android:id="@+id/tvPaid1" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_alignLeft="@+id/conditions" android:layout_alignRight="@+id/etxtname" android:layout_below="@+id/tProfileTitle" android:layout_marginTop="19dp" android:gravity="center" android:text="Profile Creation" android:textColor="#ff0000" android:textSize="25sp" android:textStyle="bold|normal" android:typeface="sans" /> <ImageView android:id="@+id/profilePicturePreview" android:layout_width="132dp" android:layout_height="120dp" android:layout_below="@+id/tvPaid4" android:layout_marginTop="14dp" android:layout_toRightOf="@+id/texperience" android:alpha="1" android:background="#FF000000" android:cropToPadding="true" android:padding="3dp" android:scaleType="centerCrop" /> <TextView android:id="@+id/tvPaid4" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_alignLeft="@+id/sbseekBarMinimumAge" android:layout_alignTop="@+id/tSex" android:text="Upload your profile picture" android:textSize="20sp" android:textStyle="bold" android:typeface="sans" /> </RelativeLayout> </ScrollView> 
Sign up to request clarification or add additional context in comments.

6 Comments

thank you much for your response. I still seem to have the same issue. I have updated my code and provide an update under my initial post. Unfortunatetly setFocusable seems to have no effect
add this to your RelativeLayout android:descendantFocusability=blocksDescendants and for all EditTex android:focusable =false
thank you. this has brought the activity to the top, but now, the edittext has become unusuable, where when i can no longer type in them
with android:descendantFocusability=blocksDescendants, it brings it to top, but then all edittext becomes non-functional
If you have a listview inside a scrollview, then set the setFocusable(false); on the listview.
|
0

Remove these attributes because ScrollView is the top view in your xml file

android:layout_gravity="top|center" android:layout_alignParentTop="true" 

Also remove

<requestFocus /> 

In this TextView both padding and margin are provided check if you really need it.

<TextView android:id="@+id/tProfileTitle" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_alignParentLeft="true" android:layout_alignParentTop="true" android:layout_marginTop="12dp" android:padding="10dp" android:text="Welcome to Dooba. We provide you with a date for everything you want to do. To begin, please fill out all of the information below." android:textSize="20sp" android:textStyle="normal|bold" android:typeface="sans" /> 

Modify your RelativeLayout like this

<RelativeLayout android:id="@+id/main" android:layout_width="match_parent" android:layout_height="797dp" android:descendantFocusability="beforeDescendants"> 

1 Comment

thank you much for your response. I still seem to have the same issue. I have updated my code and provide an update under my initial post

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.