单项选择题

You use Microsoft .NET Framework 4 to create a Windows Presentation Foundation (WPF) application.  
You write the following code fragment.

You create an event handler named StackPanel_PreviewTextInput. You also have a collection of strings named Keywords. 
You need to ensure that TxtBoxA and TxtBoxB do not contain any of the strings in the Keywords collections. 
Which code segment should you use?()

A.
B.
C.
D.


您可能感兴趣的试卷

你可能感兴趣的试题

1.单项选择题

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?()

A. lbDetails.ItemsPanel.FindName("detail",lbDetails);
B. var tmpl = (ControlTemplate)FindResource("detail"); lbDetails.Template = tmpl; 
C. var tmpl = (DataTemplate)FindName("detail"); lbDetails.ItemTemplate = tmpl;
D. var tmpl = (DataTemplate)FindResource("detail"); lbDetails.ItemTemplate=tmpl;

6.单项选择题

You use Microsoft .NET Framework 4 to create a Windows Forms application.
You write the following code segment. (Line numbers are included for reference only.)
01sealed class FormSettings :

You need to ensure that the first time each user opens the application, a text field displays the following message: "Please enter your setting."
Which code segment should you insert at line 03?()

A. [UserScopedSetting()] [DefaultSettingValue("Please enter your setting.")]
B. [UserScopedSetting()] [SettingsDescription("Description: Please enter your setting.")]
C. [ApplicationScopedSetting()] [DefaultSettingValue("Please enter your setting.")]
D. [ApplicationScopedSetting()] [SettingsDescription("Description: Please enter your setting.")]

8.单项选择题

You are developing a Windows Presentation Foundation (WPF) application for a travel reservation system
You need to ensure that users can select a range of travel dates.
What should you do ?()

A. Add single DatePicker control to the design surface
B. Add single Calendar control to the design surface
C. Add single MediaElement control to the design surface to display a calendar
D. Add the appropriate Windows Forms references to the project references. Add a single Windows Forms DateTimePicker control to the design surface

9.单项选择题Where can you check the value of a dependency property? ()

A. WPF visualizer
B. in locals
C. WPF tree visualizer

最新试题

You are developing a Windows Presentation Foundation (WPF) application. You need to use XAML to create a custom control that contains two Button controls.From which base class should you inherit? ()

题型:单项选择题

You are developing a Windows Presentation Foundation (WPF) application.You need to display HTML content from a Web Page on the WPF form. What should you do?()

题型:单项选择题

You use Microsoft .NET Framework 4 to create a Windows Presentation Foundation (WPF) application. The application has a window named MainWindow that has a StackPanel control named sp as the root element. You want to create a Button control that contains a TextBlock control with the "Save" Text property. You need to create the control dynamically and add the control to sp. Which code segment should you write in the constructor of the MainWindow class?()

题型:单项选择题

You upgrade a Windows Forms application to Microsoft .NET Framework 4. The application was developedby using a previous version of the .NET Framework. The application uses the Code Access Security (CAS) policy for file access. When the application is executed, you receive the following exception:  "NotSupportedException: This method uses CAS policy, which has been obsoleted by the .NET Framework." You need to resolve the error. What should you do?()

题型:单项选择题

You use Microsoft .NET Framework 4 to create an application. The application performs resource-intensive calculations that consist of multiple layers of nested looping.The application will be deployed to servers that contain varying hardware configurations. You need to ensure that the application utilizes CPU resources on the server in the most efficient manner. You want to achieve this goal by using the minimum amount of code. 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?()

题型:单项选择题

You are developing a Windows Forms application that contains a DataGridView control. The DataGridView capture the customer's name, address, and phone number.You have been asked to provide data validation in a DataGridView to prevent users from leaving the..You need to ensure that users cannot tab out of the name field without entering dataWhat should you do ?()

题型:单项选择题

You are developing a Windows Forms application that contains a DataGridView control. The DataGridView capture the customer's name, address, and phone number.You have been asked to provide data validation in a DataGridView to prevent users from leaving the..You need to ensure that users cannot tab out of the name field without entering dataWhat should you do ?()

题型:单项选择题

You are developing a Windows Presentation Foundation (WPF) application. All of the application styles are in the file name Themes.dllYou have the followiing markup segment.BlueBackground is defined in a XAML file named BlueTheme.xaml. The XAML markup is compiled into the Themes.dll file.You need to ensure that the XAML file is referenced so that the application can apply the settings in the BlueBackground style.()

题型:单项选择题

You are developing and XBAP application for your company intranet. During several development iterations, you manually executable, application, and deployement manifest to the test Web Server. You create an HTML file that has a manifest that you use for testing. During the next iteration, you enchance the XBAP application by making changes.When you use the hyperlink to the deployment manifest to test the deployment, you do not see the changes.You need to ensure that the changes you make are visible when you test the deployment from your machine.What should you do ?()

题型:单项选择题