Listen EditText event
package app.test; import android.app.Activity; import android.os.Bundle; import android.view.KeyEvent; import android.widget.EditText; import android.widget.TextView; import android.widget.TextView.OnEditorActionListener; public class Test extends Activity implements OnEditorActionListener { @Override public void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); setContentView(R.layout.main); EditText text1 = (EditText) findViewById(R.id.text1); text1.setOnEditorActionListener(this); EditText text2 = (EditText) findViewById(R.id.text2); text2.setOnEditorActionListener(this); } @Override public boolean onEditorAction(TextView v, int actionId, KeyEvent event) { return false; } } //main.xml <?xml version="1.0" encoding="utf-8"?> <LinearLayout xmlns:android="http://schemas.android.com/apk/res/android" android:layout_width="fill_parent" android:layout_height="fill_parent" android:orientation="vertical"> <EditText android:id="@+id/text1" android:layout_width="fill_parent" android:layout_height="wrap_content" android:imeOptions="actionSearch" /> <EditText android:id="@+id/text2" android:layout_width="fill_parent" android:layout_height="wrap_content" android:imeOptions="actionGo" /> </LinearLayout>