---
title: "Column Widths and a TextBlock Sizing in WPF"  
description: "Column Widths and a TextBlock Sizing in WPF"  
author: "Anonymous User"  
published: 2013-07-18  
updated: 2013-07-19  
canonical: https://www.mindstick.com/forum/1325/column-widths-and-a-textblock-sizing-in-wpf  
category: "wpf"  
tags: ["wpf"]  
reading_time: 1 minute  

---

# Column Widths and a TextBlock Sizing in WPF

Hi [developers](https://www.mindstick.com/articles/12875/blunders-you-must-avoid-while-hiring-java-developers-to-get-the-best-fulfilling-your-needs)!

I have a [grid](https://www.mindstick.com/forum/369/how-can-i-add-a-column-name-to-my-grid) in xaml that has two columns with widths 4.5* and 5.5*

In [column](https://www.mindstick.com/forum/33860/how-to-calculate-column-summary-in-sql-server) 1 i have a textblock. When this textblock has text that is very [long](https://www.mindstick.com/articles/44565/white-wedding-dresses-long-prom-dresses) it is making the textblock column very wide and my [second](https://answers.mindstick.com/qa/41761/how-did-the-second-industrial-revolution-influence-women-s-roles-in-society) column is getting smaller.

I need the textblock column to stay the wide that is set and [wrap the text](https://answers.mindstick.com/qa/31738/how-can-you-wrap-the-text-within-a-cell-in-excel) instead.

Here is the xaml:

```
<Grid>    <Grid.RowDefinitions>        <RowDefinition Height="25"  />    </Grid.RowDefinitions>    <Grid.ColumnDefinitions>        <ColumnDefinition Width="4.5*"/>        <ColumnDefinition Width="5.5*"/>    </Grid.ColumnDefinitions>    <TextBlock x:Name="lblCheck" Text="{Binding Path=Text}"  Grid.Column="0"  Grid.Row="0" TextWrapping="Wrap" Margin="5,0,0,0"/>    <CheckBox x:Name="chkOption" Grid.Column="1" IsChecked="{Binding Path=Checked}" Grid.Row="0"  IsEnabled="True"/></Grid>
```

Thanks

## Replies

### Reply by shreesh chandra shukla

Solution!

The code you posted works fine, other than the fact your RowHeight is set to 35 so it only shows at most 2 lines of [text](https://www.mindstick.com/blog/301635/did-people-reinvent-texting-to-express-the-full-range-of-emotions) for me.

Try setting your RowHeight to *

\


---

Original Source: https://www.mindstick.com/forum/1325/column-widths-and-a-textblock-sizing-in-wpf

Copyright © MindStick Software Pvt. Ltd. This Markdown version is provided for developers, AI systems, and offline reading.
