Web Developer Framework 4.0 Sample Questions – 30

Question: You are adding a Windows Communication Foundation (WCF) service to an existing application. The application is configured as follows. (Line numbers are included for reference only.)
01 <configuration>
02 <system.serviceModel>
03 <services>
04 <service name=”Contoso.Sales.StockService”
05 behaviorConfiguration=”MetadataBehavior”>
06 <host>
07 <baseAddresses>
08 <add baseAddress=”http://contoso.com:8080/StockService” />
09 </baseAddresses>
10 </host>
11 </service>
12 </services>
13 <behaviors>
14 <serviceBehaviors>
15 <behavior name=”MetadataBehavior”>
16 </behavior>
17 </serviceBehaviors>
18 </behaviors>

You need to configure the service to publish the service metadata. Which two actions should you perform (Each correct answer presents part of the solution. Choose two.)

  1. Add the following XML segment between lines 10 and 11.
    <endpoint address=""
    binding="mexHttpBinding"
    contract="IMetadataExchange"
    />
  2. Add the following XML segment between lines 10 and 11.
    <endpoint address=""
    binding="basicHttpBinding"
    contract="IMetadataExchange"
    />
  3. Add the following XML segment between lines15 and 16.
    <serviceDiscovery>
    <announcementEndpoints>
    <endpoint address=""/>
    </announcementEndpoints>
    </serviceDiscovery>
  4. Add the following XML segment between lines 15 and 16
    <serviceMetadata httpGetEnabled="true"/>

Correct Answer: 1 & 4


Question: You are designing an ASP.NET Web application by using Microsoft Visual Studio 2010. The Web application uses dynamic HTML (DHTML). You need to ensure that the application functions properly on multiple browser platforms without requiring the installation of a client-side component. Which two approaches could you recommend (Each correct answer presents a complete solution. Choose two.)

  1. Use jQuery.
  2. Use Microsoft Silverlight.
  3. Use the ASP.NET Ajax Library.
  4. Use Microsoft Visual Basic Scripting Edition (VBScript).

Correct Answer: 1 & 3


Question: Four Windows Communication Foundation (WCF) services are hosted in Microsoft Internet Information Services (IIS). No behavior configuration exists in the web.config file. You need to configure the application so that every service and endpoint limits the number of concurrent calls to 50 and the number of concurrent sessions to 25.Which XML segment should you add to the system.serviceModel configuration section of the web.config file

  1. <behaviors>
    <serviceBehaviors>
    <behavior name="*">
    <serviceThrottling maxConcurrentCalls="50" maxConcurrentSessions="25"/>
    </behavior>
    </serviceBehaviors>
    </behaviors>
  2. <behaviors>
    <serviceBehaviors>
    <behavior name="default">
    <serviceThrottling maxConcurrentCalls="50" maxConcurrentSessions="25"/>
    </behavior>
    </serviceBehaviors>
    </behaviors>
  3. <behaviors>
    <serviceBehaviors>
    <behavior name="">
    <serviceThrottling maxConcurrentCalls="50" maxConcurrentSessions="25"/>
    </behavior>
    </serviceBehaviors>
    </behaviors>
  4. <behaviors>
    <serviceBehaviors>
    <behavior name="ALL">
    <serviceThrottling maxConcurrentCalls="50" maxConcurrentSessions="25"/>
    </behavior>
    </serviceBehaviors>
    </behaviors>

Correct Answer: 3


Question: You are designing an ASP.NET Web Forms application. You have the following requirements:

  • Make use of exclusive features in a newly released Web browser.
  • Do not change existing code files.

You need to design the application to meet the requirements.
Which approach should you recommend

  1. Use a .browser file.
  2. Use the HttpWorkerRequest class.
  3. Use the Web application’s master page.
  4. Parse the UserAgent string in Page_Load.

Correct Answer: 1


Question: You might need to use the scroll bar to view the entire contents of the question. You are designing an ASP.NET Web application for content management. You have the following requirements:

  • Support multiple languages.
  • Support dynamic changes to site content.
  • Provide the ability to add content to the site without making changes to files within the application directory.

You need to design the application to meet the requirements.
Which source should you recommend

  1. a database based on CurrentUICulture
  2. a master page based on CurrentUICulture
  3. local resources based on CurrentCulture
  4. global resources based on CurrentCulture

Correct Answer: 1

Tagged . Bookmark the permalink.

Leave a Reply