You work as a Software Developer for ABC Inc. The company uses Visual Studio.NET 2008 as its application development platform. You create an ASP.NET Web application using the .NET Framework 3.5. 91. The application uses ASP.NET AJAX, and you need to deploy it in a Web farm environment. You are required to configure SessionState for the application. Which of the following code segments will you use to accomplish this task?
A.
B.
C.
D.
You work as a Software Developer for ABC Inc. The company uses Visual Studio .NET 2008 as its application development platform. You create an ASP.NET Web application using .NET Framework 3.5. You need to represent a strongly typed lambda expression as a data structure in the form of an expression tree. Which of the following classes will you use to accomplish the task?
A. MethodCallExpression
B. Expression
C. LambdaExpression
D. Expression(TDelegate)
Mark works as a Software Developer for GenTech Inc. He develops an application, named App1, using Visual Studio .NET. The application contains a Form control, named Form1, which enables users to edit information in a SQL Server database. Mark wants to save all the changes made by users in the database. He defines a boolean variable, named DataIsSaved, in the application code. DataIsSaved indicates whether or not all data are saved in the database. Mark wants to prevent Form1 from closing until all the changes are saved in the database. Which of the following code will he use to accomplish this?
A. protected void Form1_Leave(object sender, System.ComponentModel.CancelEventArgs e) { if(!DataIsSaved)
B. Cancel = false; else
C. Cancel = true; }
D. protected void Form1_Leave(object sender, System.ComponentModel.CancelEventArgs e) { if(!DataIsSaved)
E. Cancel = true; else
F. Cancel = false; }
G. protected void Form1_Closed(object sender, System.ComponentModel.CancelEventArgs e) { if(!DataIsSaved)
H. Cancel = false; else
I. Cancel = true; }
J. protected void Form1_Closing(object sender, System.ComponentModel.CancelEventArgs e) { if(!DataIsSaved)
K. Cancel = false; else
L. Cancel = true; }
M. protected void Form1_Closed(object sender, System.ComponentModel.CancelEventArgs e) { if(!DataIsSaved)
N. Cancel = true; else
O. Cancel = false; }
P. protected void Form1_Closing(object sender, System.ComponentModel.CancelEventArgs e) { if(!DataIsSaved)
Q. Cancel = true; else
R. Cancel = false; }
Dilton works as a Software Developer for GREC Research Center (Central). This research center has its subsidiaries in several different cities. Dilton wants to retrieve a Soil Test Report for the Geological Survey Department. He wants the test report to be available to all the members of the department over the Internet. He creates an XML Web service named SampleReport. SampleReport contains a Web method named SoilTestDetails that requires additional security.
Dilton decides to use generic role-based security to secure the SoilTestDetails method from unauthorized users. Dilton writes code to ensure that once a user is authenticated, a user identity named Generic is created. The Generic user identity has a group membership named GeoSurvey to allow the authenticated users access to the SoilTestDetails Web method. Which of the following code segments should Dilton use to accomplish the task?
A. GenericIdentity GenIdentity = new GenericIdentity("Generic", "Custom"); string[] GeoRoles = {"GeoSurvey"}; GenericPrincipal GeoPrincipal = new GenericPrincipal(GenIdentity, GeoRoles); Thread.CurrentPrincipal = GeoPrincipal;
B. IIdentity GeoIdentity = new GenericIdentity("Generic", "Custom"); WindowsIdentity WinGeoIdentity = (WindowsIdentity) GeoIdentity; string[] GeoRoles = {"GeoSurvey"}; GenericPrincipal GenGeoPrincipal = new GenericPrincipal(WinGeoIdentity, GeoRoles ); WindowsIdentity.Impersonate(WinGeoIdentity.Token);
C. IIdentity GeoIdentity = new GenericIdentity("Generic", "GeoSurvey"); IPrincipal GeoPrincipal = new WindowsPrincipal((WindowsIdentity) GeoIdentity); Thread.CurrentPrincipal = GeoPrincipal;
D. System.Security.Principal.IIdentity MyGenericIdentity = new GenericIdentity("Generic", "Custom"); string[] GeoRoles = {"GeoSurvey"}; GenericPrincipal GenGeoPrincipal = new GenericPrincipal(MyGenericIdentity, GeoRoles); MyGenericIdentity = WindowsIdentity.GetCurrent();
Mark works as a Web Developer for TechCom Inc. He creates an ASP.NET application named
Application1 by using Visual Studio .NET. Only registered users of the company will be able to use the application. The application contains a page named UserAcc.aspx that allows new users to register themselves to the registered users' list of the company. The UserAcc page contains several text box controls that accept users' personal details such as user name, password, home address, zip code, phone number, etc. One of the text box controls on the page is named ZipProperty in which a user enters a zip code.
Mark wants to ensure that when a user submits the UserAcc page, ZipProperty must contain five numeric digits. Which of the following validation controls will he use to accomplish the task?
Each correct answer represents a complete solution. Choose two.
A. RequiredFieldValidator
B. RangeValidator
C. CompareValidator
D. RegularExpressionValidator
E. RequiredValidator
You work as a Software Developer for ABC Inc. The company uses Visual Studio.NET 2005 as its application development platform. You create a remoting application that provides stock information to customers using .NET Framework. The server component raises an event on the client computer when certain conditions are met. You must ensure that the server raises exactly one event for each client application that is registered for the event. What will you do to accomplish this task?
A. Configure the server class as a Singleton Activated Object (SAO) and check for duplicate client delegate methods before raising the event.
B. Configure the server class as a Client Activated Object (CAO) and override the CreateObjRef method to check for duplicate client delegate methods before raising the event.
C. Configure the server class as a SingleCall Activated Object (SAO) and check for duplicate client delegate methods before raising the event.
D. Configure the server class as a Client Activated Object (CAO) and check for duplicate client delegate methods before raising the event.
You work as an ADO.NET Application Developer for ABC Inc. The company uses Microsoft Visual Studio .NET 2008 as its application development platform. You create an ADO.NET application by using .NET Framework 3.5. You are using the System.Linq.Expressions namespace. You need to specify an expression that applies a delegate or lambda expression to a list of argument expressions. Which of the following classes will you use to accomplish the task?
A. ListInitExpression
B. InvocationExpression
C. MemberAssignment
D. NewArrayExpression
You work as a Software Developer for ABC Inc. You create a Web page named MyWebForm1.aspx that displays a student's registration form. The page uses three CheckBox controls and several other Web server controls on the page. The CheckBox controls contain information about the educational qualifications. You want to ensure that a message containing educational status and relevant information is displayed as soon as a user clicks the CheckBox controls. Which of the following actions will you take to accomplish the task?
Each correct answer represents a part of the solution. Choose two.
A. Set the AutoPostBack property to false.
B. Use the CheckedChanged event.
C. Set the CausesValidation property to false.
D. Set the CausesValidation property to true.
E. Set the Checked property to true.
F. Set the AutoPostBack property to true.
Georgina works as a Software Developer for BlueChip Inc. She develops an application named App1 using Visual Studio .NET. The company wants her to deploy App1 to a customer's laptop. Georgina creates an assembly named Assembly1 to be stored in the Global Assembly Cache so that the Common Language Runtime (CLR) can locate and bind Assembly1.
As the application executes, the CLR locates the path of Assembly1 through the codebase setting. But, it finds no
Each correct answer represents a part of the solution. Choose all that apply.
A. The culture attribute of the assembly
B. Sub-directories in the application's root directory
C. The application base or root directory
D. The Gacutil.exe tool in the Global Assembly Cache
E. Previously loaded assemblies
F. The assembly's name
G. The correct version of the assembly
You work as a Software Developer for ABC Inc. The Company uses .NET Framework 2.0 as its application development platform. You are creating an application that will perform different types of comparison operations. Therefore, you decide to use only those methods that are available in all the classes of .NET Framework 2.0. Which of the following methods will you use to accomplish the task?
Each correct answer represents a complete solution. Choose all that apply.
A. Compare
B. ToString
C. Copy
D. Equals
E. GetType