Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8636907
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 12, 20262026-06-12T10:20:40+00:00 2026-06-12T10:20:40+00:00

On my graphical layout in Eclipse, the EditView, TextView, and button are where I

  • 0

On my graphical layout in Eclipse, the EditView, TextView, and button are where I want them to be. But when I run them on my phone, they are moved to a different location. Can someone help me keep them where I want them to be?

Here’s my code:

    <?xml version="1.0" encoding="utf-8"?>
    <RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
        android:layout_width="match_parent"
        android:layout_height="match_parent"
        android:background="@drawable/backgroundhdpi" >

        <EditText
            android:id="@+id/bill"
            android:layout_width="wrap_content"
            android:layout_height="wrap_content"
            android:layout_alignParentBottom="true"
            android:layout_centerHorizontal="true"
            android:layout_marginBottom="100dp"
            android:ems="10"
            android:inputType="phone"
            android:text="Enter Your Bill"
            android:textSize="18dip" />

        <Button
            android:id="@+id/calculateTip"
            android:layout_width="wrap_content"
            android:layout_height="wrap_content"
            android:layout_alignLeft="@+id/bill"
            android:layout_alignParentBottom="true"
            android:layout_marginBottom="40dp"
            android:layout_marginLeft="15dp"
            android:text="Calculate" />

        <TextView
            android:id="@+id/tipOwed"
            android:layout_width="wrap_content"
            android:layout_height="wrap_content"
            android:layout_above="@+id/bill"
            android:layout_centerHorizontal="true"
            android:layout_marginBottom="123dp"
            android:scrollHorizontally="false"
            android:text="Time to Tip!"
            android:textColor="#2c6f37"
            android:textSize="35dip"
            android:textStyle="bold" />

    </RelativeLayout>
  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-12T10:20:42+00:00Added an answer on June 12, 2026 at 10:20 am

    If I may ask, what type/unit of phone do you try to run your code? The layout of the program on a user’s view of point is, at times, dependent to the screen of the phone they are using.

    Example:

    You run the app with an Galaxy S2 emulator, and you try to run it in a Galaxy Y. With the difference of the screen resolution of the two, you could notice the difference between the space that the layout could occupy.

    Also, are you placing the images that are being used in your layout in a single drawable folder? Like for example, drawable-hdpi?
    Placing images that will be later on used by your layout in different drawable folders could affect directly the size or resolution of the image.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I'm using Eclipse graphical layout, and i want to Drag and Drop components to
I have a simple GUI table-layout I'm trying to design in eclipse, but when
Graphical Layout tab does not appear for some layout files into Eclipse I tried
Can anybody help me set the graphical layout option in eclipse to the dimensions
Can anybody help me set the graphical layout option in eclipse to the dimensions
Has anyone got the Graphical Layout working correctly in either Eclipse 3.5 or 3.6
I created a layout with the Graphical layout in Eclipse, What I see in
Eclipse Android Graphical Layout is not giving the options on properties window. example: When
I have a relative layout which works fine at runtime but in the Eclipse
How do I remove the android emulator's Status Bar inside Eclipse's Graphical Layout? My

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.