PrepAway - Latest Free Exam Questions & Answers

Category: 70-515 (v.3)

Exam 70-515: TS: Web Applications Development with Microsoft .NET Framework 4 (update October 26th, 2015)

You need to ensure that classes in the Web application project always reference the most recent version of the

You use the ASP.NET Web Application template to create an application in a new Visual Studio
solution. The project uses types that are defined in a class library project. Source code for the class
library is frequently modified. You need to ensure that classes in the Web application project always
reference the most recent version of the class library types. What should you do?

Which code segment should you add at line 07?

You are developing an ASP.NET Web page.
The page contains the following markup.
<asp:GridView ID=”gvModels” runat=”server”
onrowdatabound=”gvModels_RowDataBound”
AutoGenerateColumns=”false”>
<Columns>
<asp:BoundField DataField=”Name” HeaderText=”Model” />
<asp:TemplateField>
<ItemTemplate>
<asp:Image ID=”img” runat=”server” />
</ItemTemplate>
</asp:TemplateField>
</Columns>
</asp:GridView>
The pages code-behind file includes the following code segment. (Line numbers are included for
reference only.)
01 Private Sub gvModels_RowDataBound(ByVal sender As Object, _
02 ByVal e As GridViewRowEventArgs) _
03 Handles gvModels.RowDataBound
04 If (e.Row.RowType = DataControlRowType.DataRow) Then
05 Dim cm As CarModel =
06 DirectCast(e.Row.DataItem, CarModel)
07
08 img.ImageUrl =

09 String.Format(“images/{0}.jpg”, cm.ID)
10
11 End If
12 End Sub
You need to get a reference to the Image named img. Which code segment should you add at line
07?

Which two actions should you perform?

You use the following declaration to add a Web user control named TestUserControl.ascx to an
ASP.NET page named TestPage.aspx.
<uc:TestUserControl ID=”testControl” runat=”server”/>
You add the following code to the code-behind file of TestPage.aspx.
Private Sub TestMethod()
End Sub
You define the following delegate.
Public Delegate Sub MyEventHandler()
You need to add an event of type MyEventHandler named MyEvent to TestUserControl.ascx and
attach the pages TestMethod method to the event. Which two actions should you perform? (Each
correct answer presents part of the solution. Choose two.)

Which configuration should you add to the web.config file?

You are implementing an ASP.NET Web site that uses a custom server control named Task. Task is
defined as shown in the following list.
• Class name: Task
• Namespace: DevControls
• Assembly: TestServerControl.dll

• Base class: System.Web.UI.WebControls.WebControl
You copy TestServerControl.dll to the Web sites Bin folder.
You need to allow the Task control to be declaratively used on site pages that do not contain an
explicit @ Register directive.
Which configuration should you add to the web.config file?


Page 3 of 2612345...1020...Last »