单选题You are developing an ASP.NET MVC 2 Web application. The application contains a controller named HomeController, which has an action named Index. The application also contains a separate area named Blog. A view within the Blog area must contain an Acti

题目
单选题
You are developing an ASP.NET MVC 2 Web application. The application contains a controller named HomeController, which has an action named Index. The application also contains a separate area named Blog. A view within the Blog area must contain an ActionLink that will link to the Index action of the HomeController. You need to ensure that the ActionLink in the Blog area links to the Index action of the HomeController. Which ActionLink should you use?()
A

Html.ActionLink(Home, Index, Home)

B

Html.ActionLink(Home, Index, Home, new {area = }, null)

C

Html.ActionLink(Home, Index, Home, new {area = Blog}, null)

D

Html.ActionLink(Home, Index, Home, new {area = Home}, null)


相似考题
更多“You are developing an ASP.NET MVC 2 Web application. The app”相关问题
  • 第1题:

    You have a Microsoft ASP.NET Framework version 1.0 application. The application does not use any features that are deprecated in the Microsoft .NET Framework version 3.5. The application runs on Microsoft IIS 6.0.  You need to configure the application to use the ASP.NET Framework version 3.5 without recompiling the application.  What should you do?()

    • A、Edit the ASP.NET runtime version in IIS 6.0. 
    • B、Edit the System.Web section handler version number in the machine.config file. 
    • C、Add the requiredRuntime configuration element to the Web.config file and set the version attribute to v3.5. 
    • D、Add the supportedRuntime configuration element in the Web.config file and set the version attribute to v3.5.

    正确答案:A

  • 第2题:

    You are developing an ASP.NET Web page. The page includes a List instance. You add a FormView control to display a single Product from this list. You need to bind the list to the FormView control. Which FormView property should you set in the code-behind file?()

    • A、DataSource
    • B、DataSourceID
    • C、DataKeyNames
    • D、DataMember

    正确答案:A

  • 第3题:

    You are developing an ASP.NET Web page that will display the median value from a sequence of integer values. You need to create an extension method to compute the median value. Which interface should you add the extension method to?()

    • A、 IComparer<T>
    • B、 IEnumerable<T>
    • C、 IEnumerator<T>  
    • D、 IEqualityComparer<T>

    正确答案:B

  • 第4题:

    You work as an ASP.NET Web Application Developer for SomeCompany.  The company uses Visual Studio .NET 2010 as its application development platform. You create an ASP.NET Web application using .NET Framework 4.0. You create a Web page in the application. The Web page will get large sets of data from a data source.  You add a DataPager control to the page. You are required to display navigation controls that enable you to create a custom paging Ul for the DataPager control. What will you do?()

    • A、Use NextPreviousPagerField.
    • B、Use NumericPagerField.
    • C、Use PreviousPagerField.
    • D、Use NextPagerField.
    • E、Use TemplatePagerField.

    正确答案:E

  • 第5题:

    多选题
    You are implementing an ASP.NET Web application. Users will authenticate to the application with an ID. The application will allow new users to register for an account. The application will generate an ID for the user based on the users full name. You need to implement this registration functionality. Which two actions should you perform?()
    A

    Configure the SqlMembershipProvider in the web.config file.

    B

    Configure the SqlProfileProvider in the web.config file.

    C

    Create an ASP.NET page that contains a default CreateUserWizard control to create a new user account.

    D

    Create an ASP.NET page that contains a custom form that collects the user information and then uses the Membership.CreateUser method to create a new user account.


    正确答案: B,D
    解析: 暂无解析

  • 第6题:

    单选题
    ou are developing an ASP.NET MVC 2 application. You create a view that will be returned by action methods in multiple controllers. You need to place the view in the appropriate folder. To which subfolder within the Views folder should you add the view?()
    A

    Master

    B

    Default

    C

    Shared

    D

    Common


    正确答案: A
    解析: 暂无解析

  • 第7题:

    单选题
    You manage a server that runs Windows Server 2008. The server has the Web Server (IIS) role installed. The Web developer at your company creates a new Web site that runs an ASP.NET 3.0 Web application.  The ASP.NET Web application must run under a security context that is separate from any other ASP.NET application on the Web server.  You create a local user account and grant account rights and permissions to run the ASP.NET Web application.  You need to configure authentication for the new Web site to support the Web application. What should you do?()
    A

    Configure the Windows Authentication setting to Enabled.

    B

    Configure the Forms Authentication setting to Enabled by using all the default settings.

    C

    Configure the ASP.NET State service to log on to the new local user account by using the Services console.

    D

    Configure the ASP.NET Impersonation setting to Enabled. Edit the ASP.NET Impersonation setting by specifying the new local user account.


    正确答案: A
    解析: 暂无解析

  • 第8题:

    单选题
    You are developing an ASP.NET Dynamic Data Web application. Boolean fields must display as Yes or No instead of as a check box. You replace the markup in the default Boolean field template with the following markup.You need to implement the code that displays Yes or No. Which method of the FieldTemplateUserControl class should you override in the BooleanField class?()
    A

    OnLoad

    B

    Construct

    C

    OnDataBinding

    D

    SaveControlState


    正确答案: D
    解析: 暂无解析

  • 第9题:

    单选题
    You work as the IT professional in an international company which is named Wiikigo. You are experiencedin implementing and administering a network operating system. You are specialized in deploying servers,configuring Windows Server 2008 Terminal services and network application services, and configuring aweb services infrastructure. You are in charge of a server that runs Windows Server 2008. The server hasthe Web Server (IIS) server role installed. The Web developer at your company creates a new Web sitethat runs an ASP.NET 3.0 Web application. The ASP.NET Web application must run under a securitycontext that is separate from any other ASP.NET application on the Web server. You create a local useraccount and grant account rights and permissions to run the ASP.NET Web application. Authentication forthe new Web site should be configured to support the Web application. What action should you perform?()
    A

    The ASP.NET Impersonation setting should be configured to Enabled. Edit the ASP.NET Impersonation setting by specifying the new local user account.

    B

    The Windows Authentication setting should be configured to Enabled.

    C

    The Forms Authentication setting should be configured to Enabled by using all the default settings.

    D

    The ASP.NET State Service should be configured to log on to the new local user account by using the Services console.


    正确答案: B
    解析: 暂无解析

  • 第10题:

    单选题
    You are developing an ASP.NET MVC 2 Web application. A page makes an AJAX request and expects a list of company names in the following format. ["Adventure Works","Contoso"] You need to write an action method that returns the response in the correct format. Which type should you return from the action method?()
    A

    AjaxHelper

    B

    XDocument

    C

    JsonResult

    D

    DataContractJsonSerializer


    正确答案: B
    解析: 暂无解析

  • 第11题:

    You are developing an ASP.NET Web application. You create a master page. The master page requires a region where you can add page-specific content by using the ASP.NET page designer.  You need to add a control to the master page to define the region. Which control should you add?()

    • A、Content
    • B、ContentPlaceHolder
    • C、PlaceHolder
    • D、Substitution

    正确答案:B

  • 第12题:

    You are developing an ASP.NET Web application. The application must pass an object that contains user-specific data between multiple pages. The object ismore than 100 KB in size when serialized.You need to minimize the amount of data is sent to the user. What should you do?()

    • A、Pass the object data in a hidden field.
    • B、Store the object instance in a session variable.
    • C、Use a cookie that contains the object data.
    • D、Encode the object data and pass it in a query string parameter.

    正确答案:B

  • 第13题:

    You are developing an ASP.NET Web application. You create a master page. The master page requires a region where you can add page-specific content by using theASP.NET page designer. You need to add a control to the master page to define the region. Which control should you add?()

    • A、PlaceHolder
    • B、ContentPlaceHolder
    • C、Content
    • D、Substituition

    正确答案:B

  • 第14题:

    单选题
    You are developing an ASP.NET MVC 2 application. A view contains a form that allows users to submit their first name. You need to display the value that is submitted, and you must ensure that your code avoids cross-site scripting. Which code segment should you use?()
    A

    <%: Model.FirstName %>

    B

    <%= Model.FirstName %> 

    C

    <% Response.Write(Model.FirstName) %>  

    D

    <% Response.Write(HttpUtility.HtmlDecode(Model.FirstName)) %> 


    正确答案: A
    解析: 暂无解析

  • 第15题:

    单选题
    You are developing an ASP.NET MVC 2 Web application. The application contains a controller named Home Controller, which has an action named Index. The application also contains a separate area named Blog. A view within the Blog area must contain an Action Link that will link to the Index action of the Home Controller. You need to ensure that the Action Link in the Blog area links to the Index action of the HomeController. Which Action Link should you use?()
    A

    Html.ActionLink(Home, Index, Home)

    B

    Html.ActionLink(Home, Index, Home,  New With {.area = }, Nothing)

    C

    Html.ActionLink(Home, Index, Home,  New With {.area = Blog}, Nothing)

    D

    Html.ActionLink(Home, Index, Home,  New With {.area = Home}, Nothing)


    正确答案: B
    解析: 暂无解析

  • 第16题:

    单选题
    You are developing an ASP.NET Web page that will display the median value from a sequence of integer values. You need to create an extension method to compute the median value. Which interface should you add the extension method to?()
    A

     IComparer<T>

    B

     IEnumerable<T>

    C

     IEnumerator<T>  

    D

     IEqualityComparer<T>


    正确答案: B
    解析: 暂无解析

  • 第17题:

    单选题
    You modify an existing Microsoft ASP.NET application by using the Microsoft .NET Framework version 3.5.  You add a theme to the ASP.NET application.  You need to apply the theme to override any settings of individual controls.  What should you do?()
    A

    In the Web.config file of the application,set the Theme attribute of the pages element to the name of the theme.

    B

    In the Web.config file of the application,set the StyleSheetThemeattribute of the pages element to the name of the theme.

    C

    Add a master page to the application. In the @Master directive,set the Theme attribute to the name of the theme.

    D

    Add a master page to the application. In the @Master directive,set the StyleSheetTheme attribute to the name of the theme.


    正确答案: B
    解析: 暂无解析

  • 第18题:

    单选题
    You work as an ASP.NET Web Application Developer for SomeCompany. The company uses Visual Studio .NET 2010 as its application development platform. You create an ASP.NET MVC 2 Web application using .NET Framework 4.0. You implement a single project area in the MVC 2 Web application. In the Areas folder, you add a subfolder named MyTest. You add the following files to the appropriate sub-folders:  MyController. csMyHome.aspx  You register a route of the area, setting the route name to MyTest_default and the area name to test. You create a view named MyViews.aspx that is outside the test area. You need to add a link to MyViews.aspx that points to MyHome.aspx. Which of the following code segments will you use?()
    A

    <%= Html.ActionLink(MyTest, MyHome, new {area = test}, null)%>

    B

    <%= Html.RouteLink(MyHome, MyTest, new {area = test}, null)%> 

    C

    <%= Html.RouteLink(MyTest, MyHome, MyTest, new {area = test}, null)%>

    D

    <%= Html.ActionLink(MyTest, MyHome, MyTest, new {area = test}, null)%>


    正确答案: B
    解析: 暂无解析

  • 第19题:

    单选题
    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?()
    A

    You should use the page directive: <%@ Page StyleSheetTheme=App_Themes.Dark/>

    B

    You should use the page directive: <%@ Page Theme=App_Themes.Dark/>

    C

    You should use the page directive: <%@ Page Theme=Dark/>

    D

    You should use the page directive: <%@ Page StyleSheetTheme=Dark/>


    正确答案: D
    解析: 暂无解析