0

So I've set up my Eclipse to have the Android SDK and ADT plugin.

I set up my AVD to have a Galaxy Nexus and Galaxy S2 emulator.

I've created a new Android project and I get my blank MainActivity which simply displays "Hello World!" which is the problem.

In the Graphical Layout, I delete the "Hello World!" text to remove it. I check in the activity_main.xml and the script containing the "Hello World!" text is no longer there. I run in either emulator and everything works, but when the app opens, "Hello World!" is still there.

Here's the xml now

<FrameLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:tools="http://schemas.android.com/tools"
android:id="@+id/container"
android:layout_width="match_parent"
android:layout_height="match_parent"
tools:context="com.example.project.MainActivity"
tools:ignore="MergeRootFrame" />

I've changed nothing except removing that text. The MainActivity.java has not been touched. Is there something I'm missing?

Ashley Medway
  • 6,659
  • 7
  • 43
  • 63
Johnzo
  • 13
  • 4
  • Change the API level: http://stackoverflow.com/questions/19465049/changing-api-level-android-studio – aisha714 Apr 14 '15 at 19:53

2 Answers2

1

This was a little bit odd when it happened to me, just remove the Hello World Text View from the fragment.xml file and it should be fine.

0

that xml code is just for layout when you add smthg on layout this code will be bigger,example

<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" >
 <Button
        android:id="@+id/bb"
        android:layout_width="wrap_content"
        android:layout_height="wrap_content"
        android:layout_alignBottom="@+id/editText1"
        android:layout_centerHorizontal="true"
        android:layout_marginBottom="72dp"
        android:text="git" />

thats have only a button your code has nothing only layout

mBogaz
  • 136
  • 12
  • Yes, I'm aware. I'm saying I intentionally am trying to take out the "Hello World" text and that xml is the result of what I have left, but "Hello World" is still being displayed. – Johnzo Apr 16 '14 at 21:25