В настоящее время я изучаю некоторый Android для школьного проекта, и я не могу найти способ динамической установки текста в TextView.
Вот мой код:
protected void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
setContentView(R.layout.activity_enviar_mensaje);
err = (TextView)findViewById(R.id.texto);
err.setText("Escriba su mensaje y luego seleccione el canal.");
}
В настоящее время это не работает, и я не могу найти способ заставить его работать...
Любая помощь будет очень аппетитной... Спасибо за время, Хосе.
РЕДАКТИРОВАТЬ: Вот активность_enviar_mensaje.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="wrap_content"
...
tools:context=".EnviarMensaje" >
...
<TextView
android:id="@+id/texto"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_alignLeft="@+id/listaVista"
android:layout_alignParentBottom="true"
android:layout_alignRight="@+id/listaVista"
android:text="TextView" />
...
</RelativeLayout>
Под неработающим я подразумеваю, что показанный текст не изменяется в любой момент...