MCSD-Microsoft Certified Solutions Developer Questions

Q:

You are a Web developer for XYZ. You create an ASP.NET application that accesses sales and marketing data. The data is stored in a Microsoft SQL Server 2000 database on a server named XYZ01.


The company purchases a factory automation software application. The application is installed on XYZ01, where it creates a second instance of SQL Server 2000 named Factory and a database named FactoryDB. You connect to FactoryDB by using Windows Integrated authentication.


You want to add a page to your ASP.NET application to display inventory data from  FactoryDB. You use a SqlConnection object to connect to the database. You need to create a connection string to FactoryDB in the instance of SQL Server named Factory on XYZ01. Which string should you use?

A) ?Server=XYZ01;Data Source=Factory; Initial Catalog=FactoryDB;Integrated Security=SSPI? B) ?Server=XYZ01;Data Source=Factory; Database=FactoryDB;Integrated Security=SSP1?
C) ?Data Source=XYZ01\Factory; Initial Category=Factory; Integrated Security=SSP1? D) ?Data Source=XYZ01\Factory; Database=FactoryDB; Integrated Security=SSP1?
 
Answer & Explanation Answer: D) ?Data Source=XYZ01\Factory; Database=FactoryDB; Integrated Security=SSP1?

Explanation:

The Data Source attribute of the connection string contains the name, instance or network address of the instance of SQL Server to which to connect. In this scenario we are to connect to the Factory Instance on XYZ01 so we use XYZ01\Factory as data source. To specify the database we should either use the Database or the Initial Catalog attribute. Here we use Database=FactoryDB.

 

Incorrect Answers:

 

A, B: There is no Server attribute in the connection string. Instead we should use the Data Source attribute to specify the server and the instance.

 

C: There is no Initial Category attribute in the connection string. We can use Database or the Initial Catalog attribute to specify the database.

Report Error

View Answer Report Error Discuss

0 1960
Q:

You create an ASP.NET page that uses images to identify areas where a user can click to initiate actions. The users of the application use Internet Explorer.


You want to provide a pop-up window when the user moves the mouse pointer over an image. You want the pop-up window to display text that identifies the action that will be taken if the user clicks the image.


What should you do?

A) For each image, set the AlternateText property to specify the text you want to display, and set the ToolTip property to True. B) For each image, set the ToolTip property to specify the text you want to display.
C) In the onmouseover event handler for each image, add code that calls the RaiseBubbleEvent() method of the System.Web.UI.WebControls.Image class. D) In the onmouseover event handler for each image, add code that calls the ToString() method of the System.Web.UI.WebControls.Image class.
 
Answer & Explanation Answer: B) For each image, set the ToolTip property to specify the text you want to display.

Explanation:

WebControl.ToolTip property gets or sets the text displayed when the mouse pointer hovers over the Web server control. The use of the ToolTip property meets the requirement of this scenario.

 

Incorrect Answers:

A: The AlternateText property is used to specify the text to display if the image is not available.


C: The RaiseBubbleEvent is not useful here. ASP.NET server controls such as the Repeater, DataList and DataGrid Web controls can contain child controls that raise events. Rather than each button raising an event individually, events from the nested controls are "bubbled"—that is, they are sent to the control's parent.


D: The ToStringMethod() would not by itself provide the functionality required.

Report Error

View Answer Report Error Discuss

0 1955
Q:

You create English, French, and German versions of a test engine ASP.NET application you are developing for XYZ Inc. You have separate resource files for each language version.You need to deploy the appropriate resource file based on the language settings of the server. What should you do?

A) Create an installer and set the Installer.Context property for each version of your application. B) Create an installer that has a launch condition to verify the locale settings.
C) Create an installer that has a custom action to install only location-specific files. D) Create an installer that has an MsiConfigureProduct function to install the appropriate version.
 
Answer & Explanation Answer: C) Create an installer that has a custom action to install only location-specific files.

Explanation:

Custom actions are a Windows Installer feature that allows you to run code at the end of an installation to perform actions that cannot be handled during installation. This is an appropriate solution for this scenario as we only want to deploy the resource files on the server. 

 

Incorrect Answers:

 

A: We just want to deploy the resource files. We do not need to set the Context property in the application.

 

B: We don’t need any launch conditions. We just want to deploy the resource files.

 

D: We just want to deploy the resource files.

Report Error

View Answer Report Error Discuss

0 1786