PrepAway - Latest Free Exam Questions & Answers

What should you do?

You create a Microsoft ASP.NETWeb application by using the Microsoft .NET Framework
version 3.5.You add the following code fragment to an AJAX-enabled Web form. (Line
numbers are included for reference only.)
01 <asp:ScriptManager ID=”scrMgr” runat=”server” />
02 <asp:UpdatePanel ID=”updPanel” runat=”server”
03 UpdateMode=”Conditional”>
04 <ContentTemplate>
05 <asp:Label ID=”lblTime” runat=”server” />
06 <asp:UpdatePanel ID=”updInnerPanel”
07 runat=”server” UpdateMode=”Conditional”>
08 <ContentTemplate>
09 <asp:Timer ID=”tmrTimer” runat=”server”
10 Interval=”1000″
11 OnTick=”tmrTimer_Tick” />
12 </ContentTemplate>
13
14 </asp:UpdatePanel>
15 </ContentTemplate>
16
17 </asp:UpdatePanel>
The tmrTimer_Tick event handler sets the Text property of the lblTime Label control to the
current time of the server.You need to configure the appropriate UpdatePanel control to
ensure that the lblTime Label Control is properly updated by the tmrTimer Timer control.
What should you do?

PrepAway - Latest Free Exam Questions & Answers

A.
Set the UpdateMode=”Always” attribute to the updInnerPanel UpdatePanel control in line 07.

B.
Set the ChildrenAsTriggers=”false” attribute to the updPanel UpdatePanel control in line 02.

C.
Add the following code fragment to line 13.
<Triggers>
<asp:PostBackTrigger ControlID=”tmrTimer” />
</Triggers>

D.
Add the following code fragment to line 16.
<Triggers>
<asp:AsyncPostBackTrigger ControlID=”tmrTimer” EventName=”Tick” />
</Triggers>


Leave a Reply