package student.sol.EditTestEx;

import android.R.string;
import android.app.Activity;
import android.os.Bundle;
import android.view.View;
import android.view.View.OnClickListener;
import android.widget.Button;
import android.widget.EditText;
import android.widget.Toast;

public class EditTestExActivity extends Activity implements OnClickListener {
    /** Called when the activity is first created. */
	
	
	EditText et;
	Button   bt;
	
    @Override
    public void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        setContentView(R.layout.main);
        
        et= (EditText) findViewById(R.id.editText1);
        bt= (Button)findViewById(R.id.button1);
        
        bt.setOnClickListener(this);
        
    }

	@Override
	public void onClick(View v) {		
		if (v.getId()== R.id.button1){
			//editText ÀÔ·Â°ª
		  String msg=et.getText().toString();
		 
		  Toast.makeText(this, msg, Toast.LENGTH_SHORT).show();
		}
	}
}