You are designing a distributed application.
The application must store a small amount of insecure global information that does not change frequently.
You need to configure the application to meet the requirements.
Which server-side state management option should you use? (Each correct answer presents a complete solution. Choose all that apply.)
Answer :
Explanation:Application state is a data repository available to all classes in an ASP.NET application. Application state is stored in memory on the server and is faster than storing and retrieving information in a database. Unlike session state, which is specific to a single user session, application state applies to all users and all sessions. Therefore, application state is a useful place to store small amounts of often-used data that does not change from one user to another. The topics in this section provide information on how application state works and how to use it.SQL Database provides a relational database management system for Windows Azure and is based on SQL Server technology. With a SQL Database instance, you can easily provision and deploy relational database solutions to the cloud, and take advantage of a distributed data center that provides enterprise-class availability, scalability, and security with the benefits of built-in data protection and self-healing.References:https://msdn.microsoft.com/en-us/library/azure/bf9xhdz4(v=vs.85).aspx
You are developing an ASP.NET MVC application. The application is deployed in a web farm and is accessed by many users.
The application must handle web server failures gracefully. The servers in the farm must share the short-term state information.
You need to persist the application state during the session.
What should you implement?
Answer :
Explanation:ASP.NET session state service provides a somewhat slower service than the in-process variant as we need to make calls to a remote server. All session data is stored in memory so shutting down the state machine will wipe out all session data as well.References:https://dotnetcodr.com/2013/07/01/web-farms-in-net-and-iis-part-5-session-state-management/
You are developing an ASP.NET MVC application that will be deployed to servers on multiple networks.
The application must be compatible with multiple browsers. You must track the page number that the user is viewing in search results.
You need to program the location for storing state information.
Where should you persist state information?
Answer :
Explanation:
HOTSPOT -
You are developing an ASP.NET MVC web application that enables users to open Microsoft Excel files.
The current implementation of the ExcelResult class is as follows.
Answer :
Explanation:Target 1:Name: AcceptTypes -Synopsis: stringArray = Request.AcceptTypesReturns a String array containing theMultipurpose Internet Mail Extension (MIME) types accepted by the client. You can use this property to determine whether a client can accept certain response types, including application types such as Word or Excel, which are supported only by Internet Explorer.Target 2, Target 3:Example: Response.AddHeader("content-disposition", "attachment; filename=MyExcelFile.xls"); Response.ContentType = "application/ms-excel";Reference: Export data to Excel file with ASP.NET MVC 4 C# is rendering into view http://stackoverflow.com/questions/16346227/export-data-to-excel-file-with-asp-net-mvc-4-c-sharp-is-rendering-into-view
You are designing an HTML5 website.
You need to design the interface such that the content is viewable in all types of browsers, including screen readers.
What should you do? (Each correct answer presents a complete solution. Choose all that apply.)
Answer :
Explanation:
You are developing an ASP.NET MVC application in Visual Studio. The application supports multiple cultures.
The application contains three resource files in the Resources directory:
-> ProductDictionary.resx
-> ProductDictionary.es.resx
-> ProductDictionary.fr.resx
Each file contains a public resource named Currency with the localized currency symbol. The application is configured to set the culture based on the client browser settings.
The application contains a controller with the action defined in the following code segment. (Line numbers are included for reference only.)
Answer :
Explanation:Only the Resources class is used.
You are developing an ASP.NET MVC application that will be deployed on a web farm.
Passwords must be stored in the web.config file and must not be readable or in a format that is easily decodable.
You need to encrypt the passwords that are stored in the web.config file.
Which command-line tool should you use?
Answer :
Explanation:References:http://msdn.microsoft.com/en-us/library/zhhddkxy(v=vs.100).aspx
You are developing an ASP.NET MVC web application that includes the following method.
Answer :
Explanation:
You are developing an ASP.NET MVC application by using Visual Studio.
The application throws and handles exceptions when it runs.
You need to examine the state of the application when exceptions are thrown.
What should you do?
Answer :
Explanation:Configuring the debugger to break for first chance exceptionsTo change when the debugger breaks, go to Debug->Exceptions…
You are developing an ASP.NET MVC web application for viewing a photo album. The application is designed for devices that support changes in orientation, such as tablets and smartphones. The application displays a grid of photos in portrait mode.
When the orientation changes to landscape, each tile in the grid expands to include a description. The HTML that creates the gallery interface resembles the following markup.
Answer :
Explanation:Screen is used for computer screens, tablets, smart-phones etc. max-width is the maximum width of the display area, suchas a browser window.References:http://www.w3schools.com/cssref/css3_pr_mediaquery.asp
You are designing a distributed banking application that handles multiple customers. A user may log on to the site to perform activities such as checking balances, performing transactions, and other activities that must be done securely.
The application must store secure information that is specific to an individual user. The data must be automatically and securely purged when the user logs off.
You need to save transient information in a secure data store.
Which data store should you use?
Answer :
Explanation:ASP.NET session state enables you to store and retrieve values for a user as the user navigates ASP.NET pages in a Web application. HTTP is a stateless protocol. This means that a Web server treats each HTTP request for a page as an independent request. The server retains no knowledge of variable values that were used during previous requests. ASP.NET session state identifies requests from the same browser during a limited time window as a session, and provides a way to persist variable values for the duration of that session.References:https://msdn.microsoft.com/en-us/library/ms178581.aspx
You are developing an application that supports multiple cultures.
The application must store localized content in satellite assemblies.
You need to build the satellite assemblies.
Which tool should you use?
Answer :
Explanation:Use the Assembly Linker (Al.exe) to compile .resources files into satellite assemblies. Al.exe creates an assembly from the .resources files that you specify. By definition, satellite assemblies can only contain resources. They cannot contain any executable code.The following Al.exe command creates a satellite assembly for the application MyApp from the file strings.de.resources. al /t:lib /embed:strings.de.resources /culture:de /out:MyApp.resources.dllReferences:https://technet.microsoft.com/en-us/library/21a15yht(v=vs.85)
You are preparing for the deployment of an ASP.NET MVC application. You need to generate a deployment manifest.
Which command-line tool should you use?
Answer :
Explanation:The Manifest Generation and Editing Tool (Mage.exe) is a command-line tool that supports the creation and editing of application and deployment manifests.Incorrect:Not B: The Native Image Generator (Ngen.exe) is a tool that improves the performance of managed applications. Ngen.exe creates native imagesNot C: Al.exe generates a file with an assembly manifest, not an deployment manifest, from one or more files that are either resource files or Microsoft intermediate language (MSIL) files.Not D: Resgen.exe, the Resource File Generator, converts text (.txt or .restext) files and XML-based resource format (.resx) files to common language runtime binary (.resources) files that can be embedded in a runtime binary executable or compiled into satellite assemblies.References:http://www.devcurry.com/2011/02/important-net-framework-40-command-line.html
DRAG DROP -
You are developing an ASP.NET MVC application. The application has a view that displays a list of orders in a multi-select list box.
You need to enable users to select multiple orders and submit them for processing.
What should you do? (To answer, drag the appropriate words to the correct targets. Each word may be used once, more than once, or not at all. You may need to drag the split bar between panes or scroll to view content.)
Select and Place:
Answer :
You are developing an ASP.NET MVC application.
The application provides a RESTful API for third-party applications. This API updates the information for a contact by embedding the information in the URL of an
HTTP POST.
You need to save the Contact type when third-party applications use the EditContact method.
Which code segment should you use? {Each correct answer presents a complete solution. Choose all that apply.)
Answer :
Explanation:Basics of RESTful services:REST stands for Representational State Transfer, it is a simple stateless architecture that runs over HTTPwhere each unique URL is representation of some resource. There are four basic design principles which should be followed when creating RESTful service:-> Use HTTP methods (verbs) explicitly and in consistent way to interact with resources (Uniform Interface), i.e. to retrieve a resource use GET, to create a resource use POST, to update a resource use PUT/PATCH, and to remove a resource use DELETE.Etc.