0
Ich habe untersucht, wie man UI-Elemente rein durch CodeSo fügen Sie UI-Elemente dynamisch in Android
Wie kann ich das tun?
RelativeLayout mainLayout = FindViewById<RelativeLayout>(Resource.Id.MainRelativeLayout);
TextView newText = new TextView(this);
newText.Text = "HEY THERE NEW TEXT MADE VIA CODE";
mainLayout.AddView(newText);
// Set our view from the "main" layout resource
SetContentView(Resource.Layout.Main);
I Xamarin verwende. Android – mrOak