Note that there are some explanatory texts on larger screens.

plurals
  1. PO
    text
    copied!<p>It depends if you want the label to the left of or above each textblock. </p> <p>Above is easier - just use extra textblocks in the stackpanel:</p> <pre><code>&lt;StackPanel Margin="0,0,0,17" Width="432"&gt; &lt;TextBlock Text="HIN Number" TextWrapping="Wrap" Margin="12,-6,12,0" Style="{StaticResource PhoneTextExtraLargeStyle}"/&gt; &lt;TextBlock Text="{Binding HINNumber}" TextWrapping="Wrap" Margin="12,-6,12,0" Style="{StaticResource PhoneTextExtraLargeStyle}"/&gt; &lt;TextBlock Text="Category Letter" TextWrapping="Wrap" Margin="12,-6,12,0" Style="{StaticResource PhoneTextExtraLargeStyle}"/&gt; &lt;TextBlock Text="{Binding CategoryLetter}" TextWrapping="Wrap" Margin="12,-6,12,0" Style="{StaticResource PhoneTextNormalStyle}"/&gt; &lt;TextBlock Text="Category 1" TextWrapping="Wrap" Margin="12,-6,12,0" Style="{StaticResource PhoneTextExtraLargeStyle}"/&gt; &lt;TextBlock Text="{Binding Category1}" TextWrapping="Wrap" Margin="12,-6,12,0" Style="{StaticResource PhoneTextNormalStyle}"/&gt; &lt;TextBlock Text="Category 2" TextWrapping="Wrap" Margin="12,-6,12,0" Style="{StaticResource PhoneTextExtraLargeStyle}"/&gt; &lt;TextBlock Text="{Binding Category2}" TextWrapping="Wrap" Margin="12,-6,12,0" Style="{StaticResource PhoneTextNormalStyle}"/&gt; &lt;StackPanel Visibility={Binding Category3Visibility}&gt; &lt;TextBlock Text="Category 3" TextWrapping="Wrap" Margin="12,-6,12,0" Style="{StaticResource PhoneTextExtraLargeStyle}"/&gt; &lt;TextBlock Text="{Binding Category3}" TextWrapping="Wrap" Margin="12,-6,12,0" Style="{StaticResource PhoneTextNormalStyle}"/&gt; &lt;/StackPanel&gt; &lt;/StackPanel&gt; public System.Windows.Visibility Category3Visibility { get { return string.IsNullOrEmpty(Category3) ? System.Windows.Visibility.Collapsed : System.Windows.Visibility.Visible; } } </code></pre> <p>If you want the labels to the right, use a 2 column grid to layout the controls.</p>
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload