读书人

android 中 activity 着重点

发布时间: 2013-08-29 10:33:02 作者: rapoo

android 中 activity 重点

?5.Button mybutton = ?(Button)findViewById(R.id.mybutton);

mybutton.setText(R.string.hello_world);

? ? ? ? ? ? ? ? 上例说明了在activity中获得控件的方法:findViewById(),也就解决了布局文件和java文件的沟通。

?

?

读书人网 >Android

热点推荐