EX03_07.java
上传用户:vip_99
上传日期:2021-03-27
资源大小:61159k
文件大小:1k
- package irdc.ex03_07;
- import android.app.Activity;
- import android.os.Bundle;
- import android.view.View;
- import android.widget.Button;
- import android.widget.TextView;
- public class EX03_07 extends Activity
- {
- private Button mButton1;
- private TextView mTextView1;
-
- /** Called when the activity is first created. */
- @Override
- public void onCreate(Bundle savedInstanceState)
- {
- super.onCreate(savedInstanceState);
- setContentView(R.layout.main);
-
- mButton1 =(Button) findViewById(R.id.myButton1);
- mTextView1 = (TextView) findViewById(R.id.myTextView1);
-
- mButton1.setOnClickListener(new Button.OnClickListener()
- {
- @Override
- public void onClick(View v)
- {
- // TODO Auto-generated method stub
- mTextView1.setText("Hi, Everyone!!");
- }
- });
- }
- }