我的文本视图显示空白!即使我放了一个字符串,它也显示为空白..请告诉我该怎么做
protected void OnCreate (Bundle savedInstanceState ) throws ClientProtocolException, IOException, JSONException{
super.onCreate(savedInstanceState);
setContentView(R.layout.activity_main);
TextView result = (TextView) findViewById(R.id.text1);
result.setText("TESTING");
这是我的xml
<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:tools="http://schemas.android.com/tools"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:paddingBottom="@dimen/activity_vertical_margin"
android:paddingLeft="@dimen/activity_horizontal_margin"
android:paddingRight="@dimen/activity_horizontal_margin"
android:paddingTop="@dimen/activity_vertical_margin"
tools:context=".MainActivity" >
<TextView
android:id="@+id/text1"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="@string/hello_world" />
</RelativeLayout>