PrepAway - Latest Free Exam Questions & Answers

What should you do?

You plan to activate the Developer Dashboard.

You create a command line application that contains the following code segment. (Line numbers are included for reference only.)

01 SPWebService cs = SPWebService.ContentService;
02 cs.DeveloperDashboardSettings.DisplayLevel = SPDeveloperDashboardLevel.On;

You execute the application and discover that the Developer Dashboard fails to appear. You need to ensure that the application activates the Developer Dashboard.

What should you do?

PrepAway - Latest Free Exam Questions & Answers

A.
Add the following line of code at line 03:
cs.Update();

B.
Add the following line of code at line 03:
cs.DeveloperDashboardSettings.Update();

C.
Change line 02 to the following code segment:
cs.DeveloperDashboardSettings.DisplayLevel = SPDeveloperDashboardLevel.Off;

D.
Change line 02 to the following code segment:
cs.DeveloperDashboardSettings.DisplayLevel = SPDeveloperDashboardLevel.OnDemand;

Explanation:
MNEMONIC RULE: “loooonger Update()”

Update() method of SPDeveloperDashboardSettings class causes the object to save its state and propagate changes to all the computers in the server farm.

SPDeveloperDashboardSettings Members
http://msdn.microsoft.com/en-us/library/microsoft.sharepoint.administration.spdeveloperdashboardsettings_members.aspx


Leave a Reply