black

MCPD(70-511)

登录

单项选择题

You use Microsoft Visual Studio 2010 and Microsoft . 
NET Framework 4 to create a Windows Presentation Foundation (WPF) application. 
You create a WPF window in the application.  
You add the following code segment to the application. 

The DataContext property of the window is set to an instance of the ViewModel class.  
The Data property of the ViewModel instance is initialized with a collection of BusinessObject objects. 
You add a TextBox control to the Window. 
You need to bind the Text property of the TextBox control to the Name property of the current item of the CollectionView of the DataContext object.  
You also need to ensure that when a binding error occurs, the Text property of the TextBox control is set to N/A . 
Which binding expression should you use?()

A. { Binding Path=Data/Name, FallbackValue='N/A' }
B. { Binding Path=Data.Name, FallbackValue='N/A' }
C. { Binding Path=Data/Name, TargetNullValue='N/A' } 
D. { Binding Path=Data.Name, TargetNullValue='N/A' }

相关考题

单项选择题 You use Microsoft .NET Framework 4 to create a Windows Presentation Foundation (WPF) application. You write the following code fragment. You need to ensure that the ButtonHandler method is not executed when the user clicks the CancelButton button. Which code segment should you add to the code-behind file?()

单项选择题 You use Microsoft .NET Framework 4 to create a Windows Presentation Foundation (WPF) application. You want to add an audio player that plays .wav or .mp3 files when the user clicks a button. You plan to store the name of the file to a variable named SoundFilePath. You need to ensure that when a user clicks the button, the file provided by SoundFilePath plays. What should you do?()

单项选择题 You create a Windows client application by using Windows Presentation Foundation (WPF). The application contains the following code fragment. You need to assign lbDetails to use the detail data template when btnDetails is clicked. Which code segment should you write for the click event handler for btnDetails?()

All Rights Reserved 版权所有©考试题库网(kstiku.com)

备案号:湘ICP备14005140号-3

经营许可证号:湘B2-20140064