nerdexam
Microsoft

70-355 · Question #27

Drag and Drop Question 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…

The solution involves constructing two XAML elements based on the provided answer image: 1. For the TextBox element: - x:Name attribute is set to TextBox1. - Text attribute is set to TextBox1. - Resulting snippet: <TextBox x:Name = "TextBox1" Text = "TextBox1" /> 2. For the…

Implement coding patterns

Question

Drag and Drop Question 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.

Explanation

The solution involves constructing two XAML elements based on the provided answer image:

  1. For the TextBox element:
    • x:Name attribute is set to TextBox1.
    • Text attribute is set to TextBox1.
    • Resulting snippet: <TextBox x:Name = "TextBox1" Text = "TextBox1" />
  2. For the Button element:
    • x:Name attribute is set to Button1.
    • Content attribute is set to Button2.
    • Resulting snippet: <Button x:Name = "Button1" Content = "Button2" /> Other code elements listed are not used for this specific completion.

Topics

#UWP#XAML layout#TextBox#dynamic resizing

Community Discussion

No community discussion yet for this question.

Full 70-355 Practice