How should you complete the code?

DRAG DROP
You are developing a Universal Windows Platform (UWP) app.
The app will display a text box named TextBox1 and a button named Button2.
If a user types in the text box, you need to ensure that the box is resized dynamically based on the size of the
text. The buttons must always remain to the right of the text box and must always remain aligned.
How should you complete the code? To answer, drag the appropriate code elements to the correct targets.Each element may be used once, more than once, or not at all. You may need to drag the split bar between
panes or scroll to view content.
Select and Place:

DRAG DROP
You are developing a Universal Windows Platform (UWP) app.
The app will display a text box named TextBox1 and a button named Button2.
If a user types in the text box, you need to ensure that the box is resized dynamically based on the size of the
text. The buttons must always remain to the right of the text box and must always remain aligned.
How should you complete the code? To answer, drag the appropriate code elements to the correct targets.Each element may be used once, more than once, or not at all. You may need to drag the split bar between
panes or scroll to view content.
Select and Place:

Answer:

Explanation:
The new RelativePanel implements a style of layout that is defined by the relationships between its child
elements. It’s intended for use in creating app layouts that can adapt to changes in screen resolution.
Example:

<RelativePanel>
<TextBox x:Name=”textBox1″ Text=”textbox” Margin=”5″/>
<Button x:Name=”blueButton” Margin=”5″ Background=”LightBlue” Content=”ButtonRight”
RelativePanel.RightOf=”textBox1″/>
<Button x:Name=”orangeButton” Margin=”5″ Background=”Orange” Content=”ButtonBelow”
RelativePanel.RightOf=”textBox1″ RelativePanel.Below=”blueButton”/>
</RelativePanel>

https://msdn.microsoft.com/library/windows/apps/dn894631.aspx#device_families



Leave a Reply 0

Your email address will not be published. Required fields are marked *