void InflateAndAddToVtCctorBad()
{
var grid = new Grid
{
RowDefinitions = new RowDefinitionCollection
{
new RowDefinition { Height = GridLength.Auto },
new RowDefinition { Height = GridLength.Auto },
new RowDefinition { Height = GridLength.Auto },
new RowDefinition { Height = GridLength.Auto }
}
};
Content = grid;
var label1 = new Label();
var label2 = new Label();
var label3 = new Label();
var label4 = new Label();
grid.Children.Add(label1);
grid.Children.Add(label2);
grid.Children.Add(label3);
grid.Children.Add(label4);
Grid.SetRow(label1, 0);
Grid.SetRow(label2, 1);
Grid.SetRow(label3, 2);
Grid.SetRow(label4, 3);
label1.Text = "Hello Codemotion!";
label2.Text = "Hello Codemotion!";
label3.Text = "Hello Codemotion!";
label4.Text = "Hello Codemotion!";
}