Add the following line of code to the TestUserControl.ascx.cs code-behind file. public string CityName { get { return New York; } }
Add the following line of code to the TestUserControl.ascx.cs code-behind file. protected readonly string CityName = New York;
Add the following code segment to the TestPage.aspx.cs code-behind file. protected void Page_Load(object sender, EventArgs e) { string s = testControl.CityName; }
Add the following code segment to the TestPage.aspx.cs code-behind file. protected void Page_Load(object sender, EventArgs e) { string s = testControl.Attributes[CityName]; }
第1题:
You create an ASP.NET page named TestPage.aspx that contains validation controls. You need to verify that all input values submitted by the user have been validated by testing the Page.IsValid property. Which page event should you add an event handler to?()
第2题:
You create a Web page named TestPage.aspx and a user control named contained in a file named TestUserControl.ascx.You need to dynamically add TestUserControl.ascx to TestPage.aspx. Which code segment should you use?()
第3题:
You create a Web site. You add an EditorZone control to the home page on the Web site. You need to enable users to customize the size and location of the Web Parts on their home pages.Which two controls should you add to the EditorZone control?()
A. BehaviorEditorPart
B. AppearanceEditorPart
C. PropertyGridEditorPart
D. LayoutEditorPart
第4题:
You create a control named ContosoUI for a Web application. You need to add the control to the toolbox of Microsoft Visual Studio .NET. Which two actions should you perform?()
第5题:
You are creating a custom user control. The custom user control will be used on 10 Web Forms for an ASP.NET Web site that allows users to register and log on to a personalized experience. The custom user control uses two TextBox controls and two Button controls. You need to ensure that the controls are visible only when users are not logged on to the Web site. You also need to minimize the amount of effort in development and maintenance for the Web site. Which two actions should you perform? ()
第6题:
You work as a Web Developer at Certkiller.com. You are in the process of creating a Webapplication using Microsoft ASP.NET 3.5. You create a folder named Dark in the App_Themes folder of the Web application. You also addfour skin files to this folder. You have to make sure that the controls on a page have their appearances overridden by the control definitions defined in the skin files. What should you do? Which Page directive should you use?()
第7题:
You create a Web server control named ContosoControls. You add a Web custom control named ContosoMailer to it. You then distribute the Web Control Library files to your team. You need to provide your team with the correct procedure for adding the Web Control Library to the items in the toolbox of Microsoft Visual Studio .NET. Which procedure should you provide to the team?()
第8题:
You create a master page named PageBase.master. The master page contains a Label control named lblTitle.You create a content page that references the master page.You need to change the Text property of the master page‘s lblTitle control from the content page.Which code segment should you use?()
A.
B.
C.
D.
第9题:
You create a Microsoft ASP.NET application by using the Microsoft .NET Framework version 3.5. You create a custom Web user control named SharedControl. The control will be compiled as a library. You write the following code segment for the SharedControl control. (Line numbers are included for reference only.) 01 protected override void OnInit(EventArgs e) 02 { 03 base.OnInit(e); 04 05 } All the master pages in the ASP.NET application contain the following directive. <%@ Master Language="C#" EnableViewState="false" %> You need to ensure that the state of the SharedControl control can persist on the pages that reference a | English | Chinese | Japan | Korean | - 87 - Test Information Co., Ltd. All rights reserved. master page. Which code segment should you insert at line 04?()
第10题:
You create a Web page named TestPage.aspx and a user control named TestUserControl.ascx. TestPage.aspx uses TestUserControl.ascx as shown in the following line of code.