PrepAway - Latest Free Exam Questions & Answers

Author: seenagape

Which approach should you recommend?

A SharePoint 2010 server farm has a custom feature installed that provides specialized
business logic for a SharePoint solution package. The solution package is being updated to
include additional functionality. Your job is to specify a deployment method for the updates
that will: ·Add the additional application business logic to the solution package. .Provide the
least downtime for the application. .Automate the application upgrade a much as possible
You need to update the solution package with additional business logic and meet all these

requirements. Which approach should you recommend?

Which line of code should you insert at line 21?

You use Microsoft .NET Framework 4 to develop an application that connects to two separate
Microsoft SQL Server 2008 databases. The Customers database stores all the customer information,
and the Orders database stores all the order information. The application includes the following
code. (Line numbers are included for reference only.)
01 try
02 {
03 conn.Open();
04 tran = conn.BeginTransaction(“Order”);
05 SqlCommand cmd = new SqlCommand();
06 cmd.Connection = conn;
07 cmd.Transaction = tran;
08 tran.Save(“save1”);
09 cmd.CommandText – “INSERT INTO [Cust].dbo.Customer ” +
“(Name, PhoneNumber) VALUES (‘Paul Jones’, “ + “‘404-555-1212’)”;
10 cmd.ExecuteNonQuery(); iltran.Save(“save2”);
12 cmd.CommandText = “INSERT INTO [Orders].dbo.Order ” +
“(CustomerID) VALUES (1234)”;
13 cmd.ExecuteNonQuery();
14 tran.Save(“save3”);
15 cmd.CommandText = “INSERT INTO [Orders] .dbo.” +
“OrderDetail (OrderlD, ProductNumber) VALUES” + “(5678, ‘DC-6721’)”;
16 cmd.ExecuteNonQuery();
17 tran.Commit();
18 }
19 catch (Exception exj
20 {
21
22 }
You run the program, and a timeout expired error occurs at line 16. You need to ensure that the
customer information is saved in the database. If an error occurs while the order is being saved, you
must roll back all of the order information and save the customer information. Which line of code
should you insert at line 21?

You need to design a solution that promotes code reusability

You are creating a Windows Presentation Foundation (WPF) application by using Microsoft

.NET Framework 4 and Microsoft Visual Studio 2010. The application will consist of several
data entry forms. Each data entry form requires a user to enter phone numbers and
addresses. You need to design a solution that promotes code reusability. What should you
do?

You need to ensure that all generated entities inherit from MyBaseClass

You use Microsoft Visual Studio 2010 and Microsoft .NET Framework 4 to develop an application.
You use the Entity Framework Designer to create the following Entity Data Model.

The application contains a class as shown in the following code segment.
public class MyBaseClass : EntityObject
{
….
}
You need to ensure that all generated entities inherit from MyBaseClass.
What should you do?

Which code segment should you use?

You use Microsoft Visual Studio 2010 and Microsoft .NET Framework 4 to develop an application
that uses the Entity Framework. The application defines the following Entity Data Model.

Within the .edmx file, the following function is defined,
<Funccion Naroe=”Round” ReturnType=”Decimal”>
<Parameter Name=”val” Type=”Decimal” />
<DefiningExpression>
CAST(val as Edm.Int32)
</DefiningExpcession>
</Function>
The application includes the following LINQ query.
var query = from detail in context.SalesOrderDetails
select detail.LineTotal.Round() ;
You need to ensure that the Round function executes on the database server when the query is
executed.
Which code segment should you use?

You need to ensure that the memory usage of the application remains within a specific range

You are creating a Windows Presentation Foundation (WPF) application by using Microsoft
.NET Framework 4. You create a photo album-browsing application. When the user opens
an album, pictures in the album are displayed in sets of 10. Pictures are obtained from a
windows Communication Foundation (WCF) service. Most of the memory of the application
is allocated in the native heap. The memory usage of the application increases when new
albums are opened. You need to ensure that the memory usage of the application remains
within a specific range. What should you do?

You need to ensure that the stale resource records are removed from na.contoso.com

Your company has a single Active Directory forest that has an Active Directory domain named
na.contoso.com. A server named Server1 runs the DNS Server server role. You notice stale resource
records in the na.contoso.com zone. You have enabled DNS scavenging on Server1. Three weeks
later, you notice that the stale resource records remain in na.contoso.com. You need to ensure that
the stale resource records are removed from na.contoso.com. What should you do?