欢迎来到牛牛题库网 牛牛题库官网
logo
全部科目 > 微软认证考试 > MCPD > MCPD(70-562)

单项选择题

Certkiller.com has hired you as a system administrator for their network. You make use of .NETFramework v3.5 in order to create a Microsoft ASP.NET application. 
You decide to create a Web form. You add the subsequent code fragment to the Web form.<asp:Repeater ID="rept1" runat="server" DataSourceID="ds1" ItemDataBound="rept1_b"><ItemTemplate>
<asp:Label ID="lblQty" runat="server" Text=’<%# Eval("Qty") %>’ />
</ItemTemplate>
</asp:Repeater> 
The DataSource control named CKDataSource recovers the Quantity column values from a tablenamed Orders. You the create the rptData_ItemDataBound event handler using the subsequentcode fragment. (The line numbers is included for reference purposes) 
1 protected void rept_b(object sender, RepeaterItemEventArgs e)
2 {
3
4 if(CKLbl != null)
5 if(int.Parse(CKLbl.Text) < 10)6 CKLbl.ForeColor = Color.Red;7 } 
You receive an instruction from management to recover a reference to the lblQuantity Labelcontrol into a variable. The variable is named CKLbl. 
What should you do?()

A.Your best option would be to insert Label CKLbl = e.Item.FindControl("lblQty") as Label at line4.
B.Your best option would be to insert Label CKLbl = Page.FindControl("lblQty") as Label at line 4.
C.Your best option would be to insert Label CKLbl = rptData.FindControl("lblQty") as Label at line4.
D.Your best option would be to insert Label CKLbl = e.Item.Parent.FindControl("lblQty") as Labelat line 4

点击查看答案

相关考题

单项选择题
单项选择题

ou are the newly appointed system administrator at Certkiller.com. A former administratorcreated a Microsoft ASP.NET Web application using Microsoft .NET Framework v3.5. 
You are responsible for maintaining the Web application. You use the source control repository toacquire the most recent version of the project. As soon as you attempt to compile the project onyour workstation you notice that the assembly reference is missing. To ensure productivity youneed to make sure that you are able to compile the project on your workstation.
What should you do?()

A.Your best option would be to ensure that the assembly reference is deleted.Thereafter you need to add a reference to the missing assembly.
B.Your best option would be to ensure that a reference path in the property pages of the project is added to the location of the missing assembly.
C.Your best option would be to ensure that a working directory in the property pages of theproject is added to the location of the missing assembly.
D.Your best option would be to ensure that the output path in the property pages of the project is changed to the location of the missing assembly.

微信小程序免费搜题
微信扫一扫,加关注免费搜题

微信扫一扫,加关注免费搜题