PrepAway - Latest Free Exam Questions & Answers

Author: seenagape

What should you do?

The entity data model must be configured to provide a way you cal the sp_FindObsolete stored procedure.
The returned data must implement the Descendants property.

In Visual Studio 2010, you open the Add functions Import dialog box from the EDMX diagram and enter the information
shown in the following graphic.

You need to complete the configuration in the dialog box. What should you do?

What should you do?

You are implementing custom ASP.NET server controls.
You have a base class named RotaryGaugeControl and two subclasses named CompassGaugeControl and SpeedGaugeControl.
Each control requires its own client JavaScript code in order to function properly.
The JavaScript includes functions that are used to create the proper HTML elements for the control.
You need to ensure that the JavaScript for each of these controls that is used in an ASP.NET page is included in the generated HTML page only once, even if the ASP.NET page uses multiple instances of the given control.
What should you do?

Which URL should you use for the query?

You use Microsoft Visual Studio 2010 and Microsoft .NET Framework 4 to create a Windows Communication Foundation (WCF) Data Services service. You deploy the service to the following URL: http://contoso.com/Northwind.svc. You want to query the WCF Data Services service to retrieve a list of customer objects. You need to ensure that the query meets the following requirements: “Only customers that match the following filter criteria are retrieved: City=”Seattle” AND Level > 200. “Data is sorted in ascending order by the ContactName and Address properties. Which URL should you use for the query?

Which XML segment should you add to the system.serviceModel/diagnostics/messageLogging/filters configuration e

A Windows Communication Foundation (WCF) service has the following contract.

<ServiceContract(Namespace:=”http://contoso.com”)>
Public Interface IShipping

<OperationContract()>
Function DoWork(ByVal id As Integer) As String
End Interface

This is one of several service contracts hosted by your application. All endpoints use SOAP 1.2 bindings with WSAddressing 1.0. The System.ServiceModel.MessageLogging trace source in the system.diagnostics configuration section is configured with one listener. You need to make sure that only the messages that are returned from the DoWork operation are logged. Which XML segment should you add to the system.serviceModel/diagnostics/messageLogging/filters configuration element?

What should you do?

You have a ContosoEntities context object named context and a Color object stored in a variable named color.

You write the following code:
context.Colors.DeleteObject(color);
context.SaveChanges();

When the code runs, it generates the following exception:

System.Data.UpdateException: An error occurred while updating the entries. See the inner exception for detials. —>
System.Data.SqlClient.SqlException: The DELETE satement conflicted with the REFERENCE constraint “FK_PartColor”.
The conflict occurred in database “Contoso”, table “dbo.Parts”, column ‘ColorId’

You need to resolve the exception without negatively impacting the rest of the application. What should you do?

What should you do?

You are implementing an ASP.NET page that includes the following drop-down list.

<asp:PlaceHolder ID=”dynamicControls” runat=”server”>
<asp:DropDownList ID=”MyDropDown” runat=”server”>
<asp:ListItem Text=”abc” value=”abc” />
<asp:ListItem Text=”def” value=”def” />
</asp:DropDownList>
</asp:PlaceHolder>

You need to dynamically add values to the end of the drop-down list.
What should you do?