70-511 · Question #40
You are developing a Windows Presentation Foundation (WPF) application. The main window of the application is defined by the following markup. <Grid ShoTJGridLines="True"> <Grid.ColumnDefinitions>…
The correct answer is B. Grid.ColumnSpan="2". See the full explanation below for the reasoning.
Question
You are developing a Windows Presentation Foundation (WPF) application. The main window of the application is defined by the following markup. <Grid ShoTJGridLines="True"> <Grid.ColumnDefinitions> <ColumnDefinition /> <ColumnDeiinition /> </Grid.ColumnDef initions> <Grid.RowDefinitions> <RowDefinition /> <RowDefinition /> <RowDefinition /> </Grid.RouDefinitions> <TextBlock Grid.Row="0" HorizontalAlignment="Center"> Products Shipped</TextBlock> <TextBlock Grid.Row="l" Grid.Column="0"> Quarter K/TextBlock> <TextBlock Grid.Row="2" Grid.Column-"0"> Quarter 2</TextBlock> <TextBlock Grid.Row="l" Grid.Coiumn="l"> 50000</TextBiock> <TextBlock Grid.Row="2" Grid.Coluitin="l"> 150000</TextBlock> </Grid> When the application is run, it appears as follows? You need to ensure that the TextBlock control with the contents "Products Shipped" is horizontally centered on the Grid control. Which markup segment should you add to the TextBlock control?
Options
- AGridView.ColumnCollection="l,2"
- BGrid.ColumnSpan="2"
- CManipulation.ManipulationParameter""2"
- DTextBlock.TextAlignment-"Center"
How the community answered
(21 responses)- A10% (2)
- B86% (18)
- D5% (1)
Community Discussion
No community discussion yet for this question.