PrepAway - Latest Free Exam Questions & Answers

Author: seenagape

What should you do?

You create an application by using Microsoft Visual Studio .NET 2008 and the .NET Framework 3.5. The application will be used on personal computers and mobile-based devices. The current application design is composed of the following three layers:

User interface layer
Business layer
Data access layer

You need to ensure that the application offers a custom experience to the end user based on the type of device used. You also need to ensure that code duplication is avoided. What should you do?

Which code fragment should you insert at line 11?

You create a Microsoft ASP.NET application by using the Microsoft .NET Framework version 3.5.

You add the following code fragment to the Web.config file of the application (Line numbers are included for reference only).

01 <healthMonitoring>
02 <providers>
03 <add name=”EventLogProvider”
04 type=”System.Web.Management.EventLogWebEventProvider
05 />
06 <add name=”WmiWebEventProvider”
07 type=”System.Web.Management.WmiWebEventProvider
08 />
09 </providers>
10 <eventMappings>
11
12 </eventMappings>
13 <rules>
14 <add name=”Security Rule” eventName=”Security Event”
15 provider=”WmiWebEventProvider” />
16 <add name=”AppError Rule” eventName=”AppError Event”
17 provider=”EventLogProvider” />
18 </rules>
19 </healthMonitoring>

You need to configure Web Events to meet the following requirements:

* Security-related Web Events are mapped to Microsoft Windows Management Instrumentation (WMI) events.
* Web Events caused by problems with configuration or application code are logged into the Windows Application Event Log.

Which code fragment should you insert at line 11?

Which code segment should you insert at line 03?

You create a Microsoft ASP.NET application by using the Microsoft .NET Framework
version 3.5.The application has a Web form file named MovieReviews.aspx.The
MovieReviews.aspx file connects to a LinqDataSource DataSource named LinqDataSource1
that has a primary key named MovieID.The application has a DetailsView control named
DetailsView1. The MovieReviews.aspx file contains the following code fragment. (Line
numbers are included for reference only.)
01 <asp:DetailsView ID=”DetailsView1″ runat=”server”
02 DataSourceID=”LinqDataSource1″
03
04 />
05 <Fields>
06 <asp:BoundField DataField=”MovieID” HeaderText=”MovieID”
07 InsertVisible=”False”
08 ReadOnly=”True” SortExpression=”MovieID” />
09 <asp:BoundField DataField=”Title” HeaderText=”Title”
10 SortExpression=”Title” />
11 <asp:BoundField DataField=”Theater” HeaderText=”Theater”
12 SortExpression=”Theater” />
13 <asp:CommandField ShowDeleteButton=”false”
14 ShowEditButton=”True” ShowInsertButton=”True” />
15 </Fields>
16 </asp:DetailsView>
You need to ensure that the users can insert and update content in the DetailsView1 control.
You also need to prevent duplication of the link button controls for the Edit and New
operations. Which code segment should you insert at line 03?

What should you do?

You are designing a class library by using the .NET Framework 3.5 and Microsoft SQL Server 2008. The class library will be used by several .NET applications. The class library will contain a utility class that executes advanced mathematical operations. You need to design the utility class to meet the following requirements:

It can be accessed only by other classes in the same .NET assembly.
It can be instantiated only once.

What should you do?

What should you do?

You create a Microsoft ASP.NET AJAX application by using the Microsoft .NET Framework version 3.5.
You attach Microsoft Visual Studio 2008 debugger to the Microsoft Internet Explorer instance to debug the JavaScript code in the AJAX application.
You need to ensure that the application displays the details of the client-side object on the debugger console.

What should you do?

Which hosting environment should you use?

You create an application by using Microsoft Visual Studio .NET 2008 and the .NET Framework 3.5. You configure the Windows Communication Foundation (WCF) service to be exposed by using the HTTP and TCP endpoints. You plan to deploy the WCF service. You need to identify the host environment that provides the following services:

Message-based activation
Health management
Process recycling capabilities

Which hosting environment should you use?

What should you do?

You create a Microsoft ASP.NET application by using the Microsoft .NET Framework version 3.5.

You add a Web page named HomePage.aspx in the application. The Web page contains different
controls. You add a newly created custom control named CachedControl to the Web page.

You need to ensure that the following requirements are met:

The custom control state remains static for one minute.
The custom control settings do not affect the cache settings of other elements in the
Web page.

What should you do?