user340151
user340151

Reputation:

How to design grid Rowdefinitions and Columndefinitions dynamically for Windows7 phone

i need to design grid Rowdefinitions and Columndefinitions dynamically for Windows7 phone please help me

Thanking you

Upvotes: 0

Views: 253

Answers (1)

Technium
Technium

Reputation: 423

Assuming you mean at runtime then you can easily access the grid and add what you need programatically at any time.

Simply add a Name to the grid and go to work on its RowDefinitions and ColumnDefinitions properties.

<Grid x:Name="myGrid"/>

myGrid.RowDefinitions.Add(new RowDefinition() { Height = GridLength.Auto });

Upvotes: 1

Related Questions