HelloWorld Application Problem

Put problem concerning Views, Layouts and other XML-Resources (like AndroidManifest) here.

HelloWorld Application Problem

Postby brewhutch » Fri May 29, 2009 12:52 am

I'm really new to Android Dev. I followed the tutorial :

http://developer.android.com/guide/tuto ... world.html

When I ran it, I did not get the Hello World word on the Emulator's screen.
It showed the Android word in the center of screen.

Image


HelloWorldText.java
Syntax: [ Download ] [ Hide ]
Using java Syntax Highlighting
  1. package com.example.HelloWorldText;
  2.  
  3. import android.app.Activity;
  4. import android.os.Bundle;
  5.  
  6. public class HelloWorldText extends Activity {
  7.     /** Called when the activity is first created. */
  8.     @Override
  9.     public void onCreate(Bundle savedInstanceState) {
  10.         super.onCreate(savedInstanceState);
  11.         setContentView(R.layout.main);
  12.     }
  13. }
  14.  
Parsed in 0.032 seconds, using GeSHi 1.0.8.4


main.xml
Syntax: [ Download ] [ Hide ]
Using xml Syntax Highlighting
  1. <?xml version="1.0" encoding="utf-8"?>
  2. <LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
  3.    android:orientation="vertical"
  4.    android:layout_width="fill_parent"
  5.    android:layout_height="fill_parent"
  6.    >
  7.         <TextView
  8.         android:layout_width="fill_parent"
  9.         android:layout_height="wrap_content"
  10.         android:text="Hello World"
  11.         />
  12. </LinearLayout>
  13.  
Parsed in 0.002 seconds, using GeSHi 1.0.8.4


My environments:
Android SDK 1.5
Eclipse Version: 3.4.2

Thanks,
Brew
Attachments
result.gif
(35.77 KiB) Downloaded 46 times
brewhutch
Freshman
Freshman
 
Posts: 2
Joined: Fri May 29, 2009 12:20 am

Top

Postby brewhutch » Fri May 29, 2009 4:11 am

Now I got it running. This was becase I had to wait unitl the emulator started the HOME.

Thanks
brewhutch
Freshman
Freshman
 
Posts: 2
Joined: Fri May 29, 2009 12:20 am

Top

Return to View, Layout & Resource Problems

Who is online

Users browsing this forum: Exabot [Bot] and 7 guests