Android Hello World
Step 1: File -> New -> Android Application project in eclipse (see “Android in Eclipse“ article for how to program android in eclipse).
Step 2: Create Helloworld.java class file under com.example.helloworld package, and paste the below code.
package com.example.helloworld; import android.os.Bundle; import android.provider.Settings.System; import android.app.Activity; import android.widget.EditText; import android.widget.TextView; public class HelloWorld extends Activity { @Override public void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); setContentView(R.layout.activity_hello_world); TextView agnPrint = new TextView(this); agnPrint.setText("Hello world...!!"); setContentView(agnPrint); } }
Output:
Thanks for reading this post……………!!!