Hi!
I try to show GridView in the ContentPage, using such way:
`
public class Page1Render : Xamarin.Forms.Platform.Android.PageRenderer
{
public Page1Render()
{
}
protected override void OnElementChanged(ElementChangedEventArgs<Page> e)
{
base.OnElementChanged(e);
GridView grd = new GridView(this.Context);
grd.SetColumnWidth(100);
grd.StretchMode = StretchMode.StretchColumnWidth;
grd.SetGravity(GravityFlags.Center);
grd.Adapter = new ImageAdapter(this.Context);
grd.ItemClick += (sender, args) => Toast.MakeText(this.Context, args.Position.ToString(), ToastLength.Short).Show();
this.AddView(grd, ViewGroup.LayoutParams.FillParent);
}
}
, but I don
t see GridView on the screen. Is it right way to add gridview on the ContentPage?