我創建了一個Hello World應用程序,系統生成了大部分Android語言。在沒有System.out
語句的情況下運行應用程序時,仿真器中沒有顯示「Hello」。然後,使用Eclipse教程,我讀到可以將System.out.println
語句添加到main。應用程序再次運行,但沒有輸出。我的Android「Hello World」應用程序不會說「你好」
我在這裏不理解什麼?
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:orientation="vertical"
android:layout_width="fill_parent"
android:layout_height="fill_parent"
>
<TextView
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:text="@string/hello"
System.out.println =" Hello world!"
/>
</LinearLayout>
它是在說世界嗎? – Shawn 2010-04-02 00:48:12