You need to execute SPDisposeCheck.exe before the Web Part is deployed
You create a Web Part by using Microsoft Visual Studio 2010. You need to execute
SPDisposeCheck.exe before the Web Part is deployed. What should you do?
You need to prevent the error from occurring
You have a SharePoint site collection. The root Web of the site collection has the URL
http://intranet. You plan to create a sandboxed solution that will contain a Web Part. The Web Part
will display the title of the root Web. You write the following code segment for the Web Part. (Line
numbers are included for reference only.) 01 SPSite currentSite = new SPSite(“http://intranet”); 02
03 Label currentTitle = new Label(); 04 currentTitle.Text = currentSite.RootWeb.Title; You add the
Web Part to a page in the root Web and receive the following error message: “Web Part Error:
Unhandled exception was thrown by the sandboxed code wrapper’s Execute method in the partial
trust app domain: An unexpected error has occurred.” You need to prevent the error from
occurring. What should you do?
Which class should the logging component inherit?
You are creating a Web Part that will be deployed as a sandboxed solution. You need to ensure
that the Web Part can write debugging information to the SharePoint trace logs. Which class
should the logging component inherit?
Which object should you use?
You need to create a Web Part that will store and retrieve information for the current subsite.
Which object should you use?
What should you configure in Visual Studio 2010?
You create a SharePoint solution. You deploy the SharePoint solution by using Microsoft Visual
Studio 2010. You need to prevent the Feature that is contained in the solution from being
automatically activated when you deploy the solution. What should you configure in Visual Studio
2010?
You need to ensure that when you deploy the Feature, a file named Form1.xsn is deployed to the Feature folder
You are developing a custom Feature by using Microsoft Visual Studio 2010. You need to ensure
that when you deploy the Feature, a file named Form1.xsn is deployed to the Feature folder. You
must achieve this goal by using the minimum amount of development effort. What should you do?
You need to ensure that when Feature1 is upgraded, additional configuration data is added to the property bag
You have a Feature named Feature1. You plan to create a new version of Feature1 that will
upgrade the existing version of Feature1. You need to ensure that when Feature1 is upgraded,
additional configuration data is added to the property bag of the site. What should you do?
You need to deploy the third-party assembly to the Global Assembly Cache (GAC)
You create a SharePoint solution by using Microsoft Visual Studio 2010. The SharePoint solution
contains a third-party assembly. You need to deploy the third-party assembly to the Global
Assembly Cache (GAC). What should you use?
You need to ensure that the Feature is activated for all new sites that are created by using the custom site d
You have a custom site definition. You create a custom site Feature. You need to ensure that the
Feature is activated for all new sites that are created by using the custom site definition. What
should you do?
You need to modify the application to prevent the site from loading slowly
You create a console application to manage Personal Sites. The application contains the following
code segment. (Line numbers are included for reference only.) 01 SPSite siceCollection = new
SPSite (“http://rcoss”); 02 UserProfileManager profileManager = new UserProfileManager (
Server-Context.GetContext (siteCollection)) ; 03 UserProf ile profile = prof ileManager. GetUser
Prof ile (“domainWusername”) ; 04 SPSite personalSite = profile.PersonalSite ; 05 06
siteCollection.Dispose (); You deploy the application to a SharePoint site. After deploying the
application, users report that the site loads slowly. You need to modify the application to prevent
the site from loading slowly. What should you do?