How to implement HorizontalAlignment="Stretch" in RelativePanel while creating Universal Windows Platforms 10 Apps? How to implement HorizontalAlignment="Stretch" in RelativePanel while creating Universal Windows Platforms 10 Apps? windows windows

How to implement HorizontalAlignment="Stretch" in RelativePanel while creating Universal Windows Platforms 10 Apps?


Sure, just align it left and right with panel! For example:

Horizontal stretch

<RelativePanel>    <TextBox RelativePanel.AlignLeftWithPanel="True"             RelativePanel.AlignRightWithPanel="True" /></RelativePanel>

If you want vertical stretch, do the similar thing, just align the top and bottom with panel:

Vertical stretch

<RelativePanel>    <TextBox RelativePanel.AlignTopWithPanel="True"             RelativePanel.AlignBottomWithPanel="True" /></RelativePanel>