SharePoint Interview Questions With Answers

SharePoint Brain Dump:
Microsoft 70-667 Download Microsoft Braindump 70-667 (2011)
Latest 70-573 Dumps

SharePoint Tutorials:
SharePoint Foundation 2010 Installation
Setup SharePoint Blogs Wikis and Announcements
SharePoint Object Model Map

SharePoint Tutorial's Video:
Introducing SharePoint Designer 2010
Microsoft SharePoint Workspace 2010
How to: Extracting document details with SharePoint Workflow

SharePoint Interview Questions:
SharePoint Interview Questions Part 3
SharePoint Interview Questions Part 2
SharePoint Interview Questions Part 1

Q What is Sharepoint?
Ans: Portal collaboration Software.

Q What is the difference between SharePoint Portal Server and Windows SharePoint Services?Ans: SharePoint Portal Server is the global portal offering features like global navigation and searching.Windows SharePoint Services is more content management based with document libraries andlists. You apply information to certain areas within your portal from windows sharepoint Services or directly to portal areas.

Q What is a document library?
Ans: A document library is where you upload your core documents. They consist of a row and columnview with links to the documents. When the document is updated so is the link on your site. Youcan also track metadata on your documents. Metadata would consist of document properties.

Q What is a meeting workspace?
Ans: A meeting workspace is a place to store information, attendees, and tasks related to a specificmeeting.

Q What is a document workspace?
Ans: Document workspaces consist of information surrounding a single or multiple documents.

Q What is the difference between a document library and a form library?
Ans:Document libraries consist of your core documents. An example would be a word document,excel, Powerpoint, visio, pdf, etc… Form libraries consist of XML forms.

Q What is a web part zone?
Ans: Web part zones are what your web parts reside in and help categorize your web parts when designing a page.

Q How is security managed in SharePoint?
Ans: Security can be handled at the machine,domain, or sharepoint level.

Q How are web parts developed?
Ans: Web parts are developed in Visual Studio .Net. VS.Net offers many web part and page templates and can also be downloaded from the Microsoft Site.

Q What is a site definition?
Ans: It’s a methods for providing prepackaged site and list content.

Q What is a template?
A template is a pre-defined set of functions or settings that can be used over time. There are manytemplates within SharePoint,Site Templates, Document Templates, Document Library and ListTemplates.

Q How do you install web parts?
Ans: Web Parts should be distributed as a .CAB (cabinet) file using the MSI Installer.

Q What is CAML?
Ans: CAML stands for Collaborative Application Markup Language and is an XML-based languagethat is used in Microsoft Windows SharePoint Services to define sites and lists, including, for Eg, fields, views, or forms, but CAML is also used to define tables in the Windows SharePoint Servies database during site provisioning.

Q What is a DWP?
Ans: The file extension of a web part.

Q What is the GAC?
Ans: Global Assembly Cache folder on the server hosting SharePoint. You place your assemblies there for web parts and services to share them.

Q What are the differences between web part page gallery, site gallery,Virtual server galleryand online gallery?
Ans: Web Part Page Gallery is the default gallery that comes installed with SharePoint. Site Gallery isspecific to one site. Virtual Server gallery is specific to that virtual server and online gallery aredownloadable web parts from Microsoft.

Q What is the difference between a site and a web?
Ans: The pages in a web site generally cover one or more topics and are interconnected through hyperlinks. Most Websites have a home page as their starting point. While a Web is simply a blank site with SharePoint functionality built in; meaning you have to create the site from the ground up.

Q What is Microsoft Windows SharePoint Services? How is it related to Microsoft OfficeSharePoint Server 2007?
Ans: Windows SharePoint Services is the solution that enables you to create Web site for information sharing and document collaboration. Windows SharePoint Services — a key piece of theinformation worker infrastructure delivered in Microsoft Windows Server 2003 — providesadditional functionality to the Microsoft Office system and other desktop applications, and itserves as a platform for application development.Office SharePoint Server 2007 builds on top of Windows SharePoint Services 3.0 to provideadditional capabilities including collaboration, portal, search,Enterprise content management,business process and forms, and business intelligence.

Q. Who is Office SharePoint server 2007 designed for?
Ans: Office SharePoint Server 2007 can be used by information workers, IT administrators, and application developers.

Q. What are the main benefits of Office SharePoint Server 2007?
Ans: Office SharePoint Server 2007 provides a single integrated platform to manage intranet, extranet,and Internetapplications across the enterprise.

* Business users gain greater control over the storage, security, distribution, and management oftheir electronic content, with tools that are easy to use and tightly integrated into familiar,everyday applications.

* Organizations can accelerate shared business processes with customers and partners acrossorganizational boundaries using InfoPath Forms Services–driven solutions.

* Information workers can find information and people efficiently and easily through thefacilitated information-sharing functionality and simplified content publishing. In addition, accessto back-end data is achieved easily through a browser, and views into this data can bepersonalized.

* Administrators have powerful tools at their fingertips that ease deployment, management, and system administration, so they can spend more time on strategic tasks.

* Developers have a rich platform to build a new class of applications, called Office BusinessApplications, that combine powerful developer functionality with the flexibility and ease ofdeployment of Office SharePoint Server 2007. Through the use of out-of-the-box applicationservices, developers can build richer applications with less code.

Q. What is the difference between Microsoft Office SharePoint Server 2007 for Internet sites and Microsoft Office SharePoint Server 2007?
Ans: Microsoft Office SharePoint Server 2007 for Internet sites and Microsoft Office SharePoint Server2007 have identical feature functionality. While the feature functionality is similar, the usagerights are different.If you are creating an Internet, or Extranet, facing website, it is recommended that you useMicrosoft Office SharePoint Server 2007 for Internet sites which does not require the purchase client access licenses. Websites hosted using an “Internet sites” edition can only be used forInternet facing websites and all content, information, and applications must be accessible to nonemployees.Websites hosted using an “Internet sites” edition cannot be accessed by employees creating, sharing, or collaborating on content which is solely for internal use only, such as an Intranet Portal scenario.

Q.What suites of the 2007 Microsoft Office system work with Office SharePoint Server 2007?
Ans: Office Outlook 2007 provides bidirectional offline Synchronization with SharePoint documentlibraries, discussion groups, contacts, calendars, and tasks.vabnix.page.tlMicrosoft Office Groove 2007, included as part of Microsoft Office Enterprise 2007, will enablebidirectional offline synchronization with SharePoint document libraries.Features such as the document panel and the ability to publish to Excel Services will only beenabled when using Microsoft Office Professional Plus 2007or Office Enterprise 2007.Excel Services will only work with documents saved in the new Office Excel 2007 file format(XLSX).

Q. How do I invite users to join a Windows SharePoint Services Site? Is the site secure?
Ans: SharePoint-based Web sites can be password-protected to restrict access to registered users, whoare invited to join via e-mail. In addition, the site administrator can restrict certain members' rolesby assigning different permission levels to view post and edit.

Q Can I post any kind of document?
Ans: You can post documents in many formats, including .pdf, .htm and .doc. In addition, if you areusing Microsoft Office XP, you can save documents directly to your Windows SharePointServices site.

Q Can I create custom templates?
Ans: Yes you can. You can have templates for business plans, doctor's office, lawyer's office etc.

Q. How can I make My site public?
Ans: By default, all sites are created private.If you want your site to be a public Web site, enable anonymous access for the entire site. Then you can give out your URL to anybody in yourbusiness card, e-mail or any other marketing material. The URL for your Web site will be:http:// yoursitename.wss.bcentral.comHence, please take special care to name your site.These Web sites are ideal for information and knowledge intensive sites and/or sites where youneed to have shared Web workspace.Remember: Under each parent Web site, you can create up to 10 sub-sites each with uniquepermissions, settings and security rights.

Q. How do the sub sites work?
Ans: You can create a sub site for various categories.
For example:* Departments - finance, marketing, IT* Products - electrical, mechanical, hydraulics* Projects - Trey Research, Department of Transportation, FDA* Team - Retention team, BPR team* Clients - new clients, old clients* Suppliers - Supplier 1, Supplier 2, Supplier 3* Customers - Customer A, Customer B, Customer C* Real estate - property A, property BThe URLs for each will be, for example:* http://yoursitename.wss.bcentral.com/finance* http://yoursitename.wss.bcentral.com/marketingYou can keep track of permissions for each team separately so that access is restricted whilevabnix.page.tlmaintaining global access to the parent site.

Q.How do I make my site non-restricted?
Ans: If you want your site to have anonymous access enabled (i.e., you want to treat it like any site onthe Internet that does not ask you to provide a user name and password to see the content of thesite), follow these simple steps:

# Login as an administrator
# Click on site settings
# Click on Go to Site Administration
# Click on Manage anonymous access
# Choose one of the three conditions on what Anonymous users can access:** Entire Web site** Lists and libraries** NothingDefault condition is nothing; your site has restricted access.
The default conditions allow you to create a secure site for your Web site.

Q. Can I ask users outside of my organization to participate in my Windows SharePointServices site?
Ans: Yes. You can manage this process using the Administration Site Settings. Simply add users via their e-mail alias and assign permissions such as Reader or Contributor.

Q. Are there any restrictions or requirements for accessing the Windows SharePoint Services?

Ans: No. There are no system or bandwidth limitations for international trial users. Additionallylanguage packs have been installed which allow users to set up sub-webs in languages other thanEnglish. These include: Arabic, Danish, Dutch, Finnish, French, German, Hebrew, Italian,Japanese, Polish, Portuguese (Brazilian), Spanish and Swedish.

Q. Are there any browser recommendations?
Ans: Yes. Microsoft recommends using the following browsers for viewing and editing WindowsSharePoint Services sites: Microsoft Internet Explorer 5.01 with Service Pack 2, MicrosoftInternet Explorer 5.5 with Service Pack 2, Internet Explorer 6, Netscape Navigator
6.2 or later.vabnix.page.

Q.What security levels are assigned to users?
Ans: Security levels are assigned by the administrator who is adding the user. There are four levels bydefault and additional levels can be composed as necessary.
* Reader - Has read-only access to the Web site.
* Contributor - Can add content to existing document libraries and lists.
* Web Designer - Can create lists and document libraries and customize pages in the Web site.
* Administrator - Has full control of the Web site.

Q.What is the difference between an Internet and an intranet site?
Ans: An internet site is a normal site that anyone on the internet can access (e.g., www.msn.com, www.microsoft.com, etc.). You can set up a site for your company that can be accessed by anyonewithout any user name and password.An intranet (or internal network), though hosted on the Web, can only be accessed by people whoare members of the network. They need to have a login and password that was assigned to them when they were added to the site by the site administrator.

Q. What is a workspace?
Ans: A site or workspace is when you want a new place for collaborating on Web pages, lists anddocument libraries. For example, you might create a site to manage a new team or project,collaborate on a document or prepare for a meeting.

Q.How customizable is the user-to-user access?
Ans: User permissions apply to an entire Web, not to documents themselves. However, you can haveadditional sub webs that can optionally have their own permissions. Each user can be given any offour default roles. Additional roles can be defined by the administrator.

Q.Can each user have access to their own calendar?
Ans: Yes there are two ways to do this,
* by creating a calendar for each user, or
* by creating a calendar with a view for each user.

Q. What types of files can I upload / post to the site?
Ans: The only files restricted are those ending with the following extensions: .asa, .asp, .ida, .idc, .idq.Microsoft reserves the right to add additional file types to this listing at any time. Also, no content that violates the terms of service may be uploaded or posted to the site.

Q.Can SharePoint be linked to an external data source?
Ans: SharePoint data can be opened with Access and Excel as an external data source. Thus, SharePoint can be referenced as an external data source. SharePoint itself cannot reference an external datasource.

Q. Can SharePoint be linked to a SQL database?
Ans: This is possible via a custom application, but it not natively supported by SharePoint or SQLServer.

Q.Can I customize my Windows SharePoint Services site?
Ans: YES! Windows SharePoint Services makes updating sites and their content from the browser easier then ever.SharePoint includes tools that let you create custom lists, calendars, page views, etc. You can apply a theme; add List, Survey and Document Library Web Parts to a page; create personalviews; change logos; connect Web Parts and more.To fully customize your site, you can use Microsoft FrontPage 2003. Specifically, you can useFrontPage themes and shared borders, and also use FrontPage to create photo galleries and top tenlists, utilize standard usage reports, and integrate automatic Web content.

Q. Will Microsoft Office SharePoint Server 2007 run on a 64-bit version of MicrosoftWindows?Ans: Windows SharePoint Services 3.0, Office SharePoint Server 2007, Office Forms Server 2007, andOffice SharePoint Server 2007 for Search will support 64-bit versions of Windows Server 2003.

Q. What are the features that the portal components of Office SharePoint Server 2007 include?

Ans: The portal components of Office SharePoint Server 2007 include features that are especially useful for designing, deploying, and managing enterprise intranet portals, corporate Internet Websites, and divisional portal sites. The portal components make it easier to connect to people withinthe organization who have the right skills, knowledge, and project experience.

Q.What are the advanced features of MOSS 2007?
Ans: * User Interface (UI) and navigation enhancements
* Document management enhancements
* The new Workflow engine
* Office 2007 Integration
* New Web Parts
* New Site-type templates
* Enhancements to List technology
* Web Content Management
* Business Data Catalog
* Search enhancements
* Report Center
* Records Management
* Business Intelligence and Excel Server
* Forms Server and InfoPath
* The “Features” feature
* Alternate authentication providers and Forms-based authentication

Q.What are the features of the new Content management in Office SharePoint 2007?
Ans: The new and enhanced content management features in Office SharePoint Server 2007 fall within three areas:

* Document management
* Records management.
* Web content managementOffice SharePoint Server 2007 builds on the core document management functionality providedby Windows SharePoint Services 3.0, including check in and check out, versioning, metadata, and role-based granular access controls. Organizations can use this functionality to deliver enhancedauthoring, business document processing, Web content management and publishing, recordsmanagement, policy management, and support for multilingual publishing.

Q.Does a SharePoint Web site include search functionality?
Ans: Yes. SharePoint Team Services provides a powerful text-based search feature that helps you finddocuments and information fast.

Q.What are the benefits of Microsoft Office SharePoint Server 2007?
Ans: * Provide a simple, familiar, and consistent user experience.* Boost employee productivity by simplifying everyday business activities.* Help meet regulatory requirements through comprehensive control over content.* Effectively manage and repurpose content to gain increased business value.* Simplify organization-wide access to both structured and unstructured information acrossdisparate systems.* Connect people with information and expertise.* Accelerate shared business processes across organizational boundaries.* Share business data without divulging sensitive information.* Enable people to make better-informed decisions by presenting business-critical information inone central location.* Provide a single, integrated platform to manage intranet, extranet, and Internet applicationsacross the enterprise.

Q.Will SharePoint Portal Server and Team Services ever merge?
Ans: The products will come together because they are both developed by the Office team.

Q.What does partial trust mean the Web Part developer?
Ans: If an assembly is installed into the BIN directory, the code must be ensured that provides errorhandling in the event that required permissions are not available. Otherwise, unhandled securityexceptions may cause the Web Part to fail and may affect page rendering on the page where theWeb Part appears.

Q.How can I raise the trust level for assemblies installed in the BIN directory?
Ans: Windows SharePoint Services can use any of the following three options from ASP.NET and the CLR to provide assemblies installed in the BIN directory with sufficient permissions. The following table outlines the implications and requirements for each option.

1.Option Pros Cons Increase the trust level for the entire virtual server.
In a development environment,increasing the trust level allows you to test an assembly with increased permissions while allowing you to recompile assemblies directly into the BIN directory without resetting IIS. This option is least secure. This option affects all assemblies used by the virtual server.There is no guarantee the destination server has the required trust level. Therefore, Web Parts may not work once installed on the destination server.

2.Create a custom policy file for your assemblies. For more information, see "How do I create acustom policy file?" Recommended approach.This option is most secure.An assembly can operate with a unique policy that meets the minimum permission requirementsfor the assembly.By creating a custom security policy, you can ensure the destination server can run your WebParts.

3.Requires the most configuration of all three options.Install your assemblies in the GACEasy to implement.This grants Full trust to your assembly without affecting the trust level of assemblies installed inthe BIN directory.This option is less secure.Assemblies installed in the GAC are available to all virtual servers and applications on a serverrunning Windows SharePoint Services. This could represent a potential security risk as itpotentially grants a higher level of permission to your assembly across a larger scope thannecessaryIn a development environment, you must reset IIS every time you recompile assemblies.Licensing issues may arise due to the global availability of your assembly.

Q. Does SharePoint work with NFS?

Ans: Yes and no.
It can crawl documents on an NFS volume, but the sharepoint database or logs cannotbe stored there.

Q.How is SharePoint Portal Server different from the Site Server?
Ans: Site Server has search capabilities but these are more advanced using SharePoint. SPS uses digital dashboard technology which provides a nice interface for creating web parts and showing them ondashboards (pages). SS doesn't have anything as advanced as that. The biggest difference wouldbe SPS document management features which also integrate with web folders and MS Office.

 

 

1.      What kind of work you did on Share Point Portal?

2.      What is WebPart and how is differe from Web User Control?

3.      What are Pros and Cons of WebParts?

4.      How you communicate between WebParts?

5.      What are the configurations you make to communicate between WebParts?

6.      What is difference between WSS and Share Point Portal?

7.      What are the things you cannot achieve in WSS compare to SPS?

8.      Is it possible to migrate old SPS Portal to SPS 2003?

9.      Can the migration tools convert all your code?

10.  What are the changes you need to do after migrating old SPS to new SPS

11.  What are the top level objects?

12.  How do you access a list inside an InfoPath Document?

13.  What are the events occurred on Document?

14.  What is the Interface you will implement for an events call?

15.  Have you work with Microsoft Office with Share Point Portal 2003?

16.  How you display Excel in Share Point Portal?

17.  How u integrate Outlook with Share Point Portal?

18.  Do you follow any standard for Share Point Portal?

19.  What is the check lists needed before moving to production mode?

20.  What the configuration you need to make for Internet based Share Point Portal site?

21.  Have you used any tools to check C# coding standards?

22.  How you do your unit testing?

23.  Do you use any mechanism to create a stub for NUnit?

24.How do you access WebParts Data from InfoPath?

25. Do u have experience on Share Point Portal administration ?

26. What is Custom List ?

27.What is back end use SPS 2003 ?

28.Can there i use oracle as my back end?

29.Explain Security Model in SPS 2003?

30.How the search happening in SPS 2003?

31.What is difference in View and List?

32.What is role of WSS in SPS 2003?

33.What is role of Active Directory in SPS 2003 ?

34.Can i operate SPS 2003 without Active Directory?

35.What is SitreGroup ?

36.What is SiteCollection?

· Everyone who can spell SharePoint

o what is SharePoint?

o what is the difference between SharePoint Portal Server and Windows SharePoint Services?

o what is a document library?

o what is a meeting workspace?

o what is a document workspace?

o what is a web part?

Mid-level SharePoint Consultant

o what is the difference between a document library and a form library?

o what is a web part zone?

o how is security managed in SharePoint?

o how are web parts developed?

o what is a site definition?

o what is a template?

o how do you install web parts?

o what is the difference between a site and a web?

o what are the differences between web part page gallery, site gallery, virtual         server gallery and online gallery?

o what is the GAC?

o what is a DWP?

o what is CAML?

o what are themes?

o what is presence?

o can web parts be connected? if so, how?

o what is a personal view and what is a shared view?

o what is an STP file?

o what is an FWP file?

o can you upload MP3's to SharePoint?

o how does SharePoint support MS Outlook integration?

o how can you extend lists in SharePoint?

o explain the document versioning in SharePoint document libraries

Senior SharePoint Consultant

o where are web part resources contained?

o what are the different installation methods for deploying web parts? and what are the pros/cons?

o what is a ghosted/unghosted page?

o how is site data stored?

o where is metadata for a web stored?

o what is an audience and describe the use?

o what are the trust levels and what is the default trust associated with SharePoint?

o what are the two logging mechanisms for usage statistics?

o what functionality does owssup.dll provide for client side activities?

o what is the difference between a site owner and a site administrator?

o what is STSAdm and what can it be used for?

o can WSS search subsites?

o can you register alerts for users?

o are PDFs searchable?

SharePoint Architect

o what is a SharePoint farm?

o describe a large deployment

o how can you synchronize custom Active Directory attributes to SharePoint?

o if it is anticipated that our organization would need to store 1 terrabyte of documents, what is the recommended configuration and storage requirement?

o describe the implementation of SharePoint and Project Server

o what are the BKMs for workflow and SharePoint?

o explain how you would deploy SharePoint on an extranet

o what is the BKM for maximum number of virtual servers configured for SharePoint on a single box?

o what are the migration strategies for moving sites around?

o what are the archiving strategies?

o describe the search strategies

o can you implement forms-based authentication with SharePoint?

o describe how single sign-on works

 

 

1) What are the two base classes a WebPart you are going to use within SharePoint 2007 can inherit from?

There are two base classes that a WebPart which is going to be consumed by SharePoint can inherit from, either the SharePoint WebPart Base class or the ASP.NET 2.0 WebPart base class. When inheriting from the SharePoint WebPart Base class your derived WebPart class will inherit from Microsoft.SharePoint.WebPartPages.WebPart. When inheriting from the ASP.NET 2.0 WebPart base class your derived WebPart class will inherit from System.Web.UI.WebControls.WebParts.WebPart. It is considered good practice to use the ASP.NET WebPart base class since the old base class is meant for backwards compatibility with previous version of SharePoint, however there are four exception when it is better to leverage functionality from the SharePoint WebPart base class:

Cross page connections

Connections between Web Parts that are outside of a Web Part zone

Client-side connections (Web Part Page Services Component)

Data caching infrastructure

2) What are the differences between the two base classes and what are the inherit benefits of using one over another?

The difference is the Microsoft.SharePoint.WebPartPages.WebPart base class is meant for backward compatibility with previous versions of SharePoint. The benefit of using the SharePoint WebPart base class is it supported:

Cross page connections

Connections between Web Parts that are outside of a Web Part zone

Client-side connections (Web Part Page Services Component)

Data caching infrastructure

ASP.NET 2.0 WebParts are generally considered better to use because SharePoint is built upon the ASP.NET 2.0 web architecture. Inheriting from the ASP.NET 2.0 base class offers you features that inherit to ASP.NET 2.0, such as embedding resources as opposed to use ClassResources for deployment of said types.

3) What is the GAC?

The GAC stands for the global assembly cache. It is the machine wide code cache which will give custom binaries place into the full trust code group for SharePoint. Certain SharePoint assets, such as Feature Receivers need full trust to run correctly, and therefore are put into the GAC. You should always try to avoid deployment to the GAC as much as possible since it will possibly allow development code to do more than it was intended to do.

4) What is strong naming (signing) a WebPart assembly file mean?

Signing an assembly with a strong name (a.k.a strong naming) uses a cryptographic key pair that gives a unique identity to a component that is being built. This identity can then be referred throughout the rest of the environment. In order to install assemblies into the GAC, they must be strongly named. After signing, the binary will have a public key token identifier which can be use to register the component in various other places on the server.

5) What are safe controls, and what type of information, is placed in that element in a SharePoint web.config file?

When you deploy a WebPart to SharePoint, you must first make it as a safe control to use within SharePoint in the web.config file. Entries made in the safe controls element of SharePoint are encountered by the SharePointHandler object and will be loaded in the SharePoint environment properly, those not will not be loaded and will throw an error.

In the generic safe control entry (this is general, there could be more), there is generally the Assembly name, the namespace, the public key token numeric, the typename, and the safe declaration (whether it is safe or not). There are other optional elements.

6) What is the CreateChildControls() method? How can you use it to do something simple like displaying a Label control?

The CreateChildControls method in WebParts is used to notify the WebPart that there are children controls that should be output for rendering. Basically, it will add any child ASP.NET controls that are called instantiating each control with its relevant properties set, wire any relevant event handlers to the control, etc. Then the add method of the control class will add the control to the controls collection. In the relevant WebPart render method, the EnsureChildControls method can be called (or set to false if no child controls should be called) to ensure that the CreateChildControls method is run. When using CreateChildControls it implies that your WebPart contains a composition of child controls.

In order to create something like a label control in Create, you would create a new label control using the new keyword, set the various properties of the control like Visible=True and ForeColor = Color.Red, and then use Controls.Add(myLabelControl) to add the control to the controls collection. Then you can declare EnsureChildControls in the Render method of the WebPart.

7) What does the RenderContents method do in an ASP.NET 2.0 WebPart?

The render contents method will render the WebPart content to the writer, usually an HtmlTextWriter since WebParts will output to an HTML stream. RenderContents is used to tell how the controls that are going to be displayed in the WebPart should be rendered on the page.

*** Side Question: I got asked what the difference between CreateChildControls and the RenderContents method. The CreateChildControls method is used to add controls to the WebPart, and the RenderContents method is used to tell the page framework how to render the control into HTML to display on a page.

What is the WebPartManager sealed class? What is its purpose?

The WebPartManager sealed class is responsible for managing everything occurring on a WebPart page, such as the WebParts (controls), events, and misc. functionality that will occur in WebPartZones. For example, the WebPartManager is responsible for the functionality that is provided when you are working with moving a WebPart from WebPartZone to WebPartZone. It is known as the “the central class of the Web Part Control Set.”

*** Side Question: I got asked how many WebPartManager controls should be on a page. In order to have WebParts on a page there has to be just one WebPartManager control to manage all the WebParts on the page.

9) What is a SPSite and SPWeb object, and what is the difference between each of the objects?

The SPSite object represents a collection of sites (site collection [a top level sites and all its subsites]). The SPWeb object represents an instance SharePoint Web, and SPWeb object contains things like the actual content. A SPSite object contains the various subsites and the information regarding them.

10) How would you go about getting a reference to a site?

PLAIN TEXT

C#:

oSPSite = new SPSite("http:/server");

 

oSPWeb = oSPSite.OpenWeb();

11) What does a SPWebApplication object represent?

The SPWebApplication objects represents a SharePoint Web Application, which essentially is an IIS virtual server. Using the class you can instigate high level operations, such as getting all the features of an entire Web Application instance, or doing high level creation operations like creating new Web Applications through code.

12) Would you use SPWebApplication to get information like the SMTP address of the SharePoint site?

Yes, since this is a Web Application level setting. You would iterate through each SPWebApplication in the SPWebApplication collection, and then use the appropriate property calls (OutboundMailServiceInstance) in order to return settings regarding the mail service such as the SMTP address.

Side Question: I got asked if there are other ways to send emails from SharePoint. The answer is yes, there is. You can use the SendMail method from the SPutility class to send simple emails, however it is not as robust as using the System.Net.Mail functionality since it doesn’t allow things like setting priorities on the email.

13) How do you connect (reference) to a SharePoint list, and how do you insert a new List Item?

PLAIN TEXT

C#:

using(SPSite mySite = new SPSite("yourserver"))

{

using(SPWeb myWeb = mySite.OpenWeb())

{

SPList interviewList = myWeb.Lists["listtoinsert"];

SPListItem newItem = interviewList.Items.Add();

 

newItem["interview"] = "interview";

newItem.Update();

}

}

14) How would you loop using SPList through all SharePont List items, assuming you know the name (in a string value) of the list you want to iterate through, and already have all the site code written?

PLAIN TEXT

C#:

SPList interviewList = myWeb.Lists["listtoiterate"];

foreach (SPListItem interview  in interviewList)

{

// Do Something

}

15) How do you return SharePoint List items using SharePoint web services?

In order to retrieve list items from a SharePoint list through Web Services, you should use the lists.asmx web service by establishing a web reference in Visual Studio. The lists.asmx exposes the GetListItems method, which will allow the return of the full content of the list in an XML node. It will take parameters like the GUID of the name of the list you are querying against, the GUID of the view you are going to query, etc.

Side Question: I got asked how I built queries with the lists.asmx web service. In order to build queries with this service, one of the parameters that the GetListItems method exposes is the option to build a CAML query. There are other ways to do this as well, but that was how I answered it.

16) When retrieving List items using SharePoint Web Services, how do you specify explicit credentials to be passed to access the list items?

In order to specify explicit credentials with a Web Service, you generally instantiate the web service, and then using the credentials properties of the Web Service object you use the System.Net.NetworkCredential class to specify the username, password, and domain that you wish to pass when making the web service call and operations.

*** Side Question: I got asked when you should state the credentials in code. You must state the credentials you are going to pass to the web service before you call any of the methods of the web service, otherwise the call will fail.

17) What is CAML, and why would you use it?

CAML stands for Collaborative Application Markup Language. CAML is an XML based language which provides data constructs that build up the SharePoint fields, view, and is used for table definition during site provisioning. CAML is responsible for rending data and the resulting HTML that is output to the user in SharePoint. CAML can be used for a variety of circumstances, overall is used to query, build and customize SharePoint based sites. A general use would be building a CAML query in a SharePoint WebPart in order to retrieve values from a SharePoint list.
18) What is impersonation, and when would you use impersonation?

Impersonation can basically provide the functionality of executing something in the context of a different identity, for example assigning an account to users with anonymous access. You would use impersonation in order to access resources on behalf of the user with a different account, that normally, that wouldn’t be able to access or execute something.

19) What is the IDesignTimeHtmlProvider interface, and when can you use it in WebParts?

The IDesignTimeHtmlProvider interface uses the function GetDesignTimeHtml() which can contain your relevant render methods. It was helpful to use in 2003 since it allowed your WebPart to have a preview while a page was edited in FrontPage with the Webpart on it, because the GetDesignTimeHtml() method contains the HTML for the designer to render.

20) What are WebPart properties, and what are some of the attributes you see when declaring WebPart properties in code?

WebPart properties are just like ASP.NET control properties, they are used to interact with and specify attributes that should be applied to a WebPart by a user. Some of the attributes you see with ASP.NET 2.0 properties are WebDescription, WebDisplayName, Category, Personalizable, and WebBrowsable. Although most of these properties come from the System.Web.UI.WebControls.WebParts class, ones like Category come out of System.ComponentModel namespace.

21) Why are properties important in WebPart development, and how have you exploited them in past development projects? What must each custom property have?

Properties are important because WebParts allow levels of personalization for each user. WebPart properties make it possible for a user to interact, adjust, and increase overall experience value with the programmatic assets that you develop without having the need to use an external editor or right any code. A very simple example of exploiting a property would be something like allowing the user to change the text on the WebPart design interface so that they can display whatever string of text they desire.

Each custom property that you have must have the appropriate get and set accessor methods.

22) What are ClassResources? How do you reference and deploy resources with an ASP.NET 2.0 WebPart?

ClassResources are used when inheriting from the SharePoint.WebPart.WebPartPages.WebPart base class, and are defined in the SharePoint solution file as things that should be stored in the wpresources directory on the server. It is a helpful directory to use in order to deploy custom images. In ASP.NET 2.0, typically things such as images are referenced by embedding them as resources within an assembly. The good part about ClassResources is they can help to eliminate recompiles to change small interface adjustments or alterations to external JavaScript files.

23) What is a SharePoint Solution File? How does it differ from WebPart .cab files in legacy development? What does it contain?

A SharePoint solution file is essentially a .cabinet file with all a developers ustom componets suffixed with a .wsp extension that aids in deployment. The big difference with SharePoint solution files is that a solution:

allows deployment to all WFE’s in a farm

is highly manageable from the interface allowing deployment, retraction, and versioning

Can package all types of assets like site definitions, feature definitions (and associated components), Webparts, etc.

Can provide Code Access Security provisioning to avoid GAC deployments

Just to name a few things…

24) What is a .ddf file and what does it have to do with SharePoint Solution creation?

A .ddf file is a data directive file and is used when building the SharePoint solution bundle specifying the source files and their destination locations. The important thing for someone to understand is that the .ddf file will be passed as a parameter to the MAKECAB utility to orchestrate construction of the SharePoint solution fiel.

25) What file does a SharePoint solution package use to orchestrate (describe) its packaged contents?

The solution Manifest.XML file.

26) What deployment mechanism can you use to instigate Code Access Security attributes for your WebParts?

SharePoint solution files can add in order to handle code access security deployment issues. This is done in the element in the SharePoint solution manifest.XML, which makes it easier to get assemblies the appropriate permissions in order to operate in the bin directory of the web application.

27) What is a SharePoint Feature? What files are used to define a feature?

A SharePoint Feature is a functional component that can be activated and deactivate at various scopes throughout a SharePoint instances, such as at the farm, site collection, web, etc. Features have their own receiver architecture, which allow you to trap events such as when a feature is installing, uninstalling, activated, or deactivated. They are helpful because they allow ease of upgrades and versioning.

The two files that are used to define a feature are the feature.xml and manifest file. The feature XML file defines the actual feature and will make SharePoint aware of the installed feature. The manifest file contains details about the feature such as functionality.

Side Question: I got asked how the introduction of features has changed the concept of site definitions. SharePoint features are important when understanding the architecture of site definitions, since the ONET.XML file has been vastly truncated since it has several feature stapled on it.

28) What types of SharePoint assets can be deployed with a SharePoint feature?

Features can do a lot. For example, you could deploy

Simple site customizations

Custom site navigation

WebParts

pages

list types

list instances

event handlers

workflows

custom actions

just to name a few….

29) What are event receivers?

Event receivers are classes that inherit from the SpItemEventReciever or SPListEventReciever base class (both of which derive out of the abstract base class SPEventRecieverBase), and provide the option of responding to events as they occur within SharePoint, such as adding an item or deleting an item.

30) When would you use an event receiver?

Since event receivers respond to events, you could use a receiver for something as simple as canceling an action, such as deleting a document library by using the Cancel property. This would essentially prevent users from deleting any documents if you wanted to maintain retention of stored data.

31) What base class do event receivers inherit from?

Event receivers either inherit from the SPListEventReciever base class or the SPItemEventReciever base class, both which derive from the abstract base class SPEventReceiverBase.

32) If I wanted to not allow people to delete documents from a document library, how would I go about it?

You would on the ItemDeleting event set: properties.Cancel= true.

33) What is the difference between an asynchronous and synchronous event receivers?

An asynchronous event occurs after an action has taken place, and a synchronous event occurs before an action has take place. For example, an asynchronous event is ItemAdded, and its sister synchronous event is ItemAdding.

34) How could you append a string to the title of a site when it is provisioned?

In the OnActivated event:

PLAIN TEXT

C#:

SPWeb site = siteCollection.RootWeb;

site.Title += "interview";

site.Update();

35) Can an event receiver be deployed through a SharePoint feature?

Yes.

36) What is a content type?

A content type is an information blueprint basically that can be re-used throughout a SharePoint environment for defining things like metadata and associated behaviors. It is basically an extension of a SharePoint list, however makes it portable for use throughout an instance regardless of where the instantiation occurs, ergo has location independence. Multiple content types can exist in one document library assuming that the appropriate document library settings are enabled. The content type will contain things like the metadata, listform pages, workflows, templates (if a document content type), and associated custom written functionality.

37) Can a content type have receivers associated with it?

Yes, a content type can have an event receiver associated with it, either inheriting from the SPListEventReciever base class for list level events, or inheriting from the SPItemEventReciever base class. Whenever the content type is instantiated, it will be subject to the event receivers that are associated with it.

38) What two files are typically (this is kept generally) included when developing a content type, and what is the purpose of each?

There is generally the main content type file that holds things like the content type ID, name, group, description, and version. There is also the ContentType.Fields file which contains the fields to include in the content type that has the ID, Type, Name, DisplayName, StaticName, Hidden, Required, and Sealed elements. They are related by the FieldRefs element in the main content type file.

39) What is an ancestral type and what does it have to do with content types?

An ancestral type is the base type that the content type is deriving from, such as Document (0x0101). The ancestral type will define the metadata fields that are included with the custom content type.

40) Can a list definition be derived from a custom content type?

Yes, a list definition can derive from a content type which can be seen in the schema.XML of the list definition in the element.

41) When creating a list definition, how can you create an instance of the list?

You can create a new instance of a list by creating an instance.XML file.

42) What is a Field Control?

Field controls are simple ASP.NET 2.0 server controls that provide the basic field functionality of SharePoint. They provide basic general functionality such as displaying or editing list data as it appears on SharePoint list pages.

43) What base class do custom Field Controls inherit from?

This varies. Generally, custom field controls inherit from the Microsoft.SharePoint.WebControls.BaseFieldControl namespace, but you can inherit from the default field controls.

44) What is a SharePoint site definition? What is ghosted (uncustomized) and unghosted (customized)?

SharePoint site definitions are the core set of functionality from which SharePoint site are built from, building from the SiteTemplates directory in the SharePoint 12 hive. Site definitions allow several sites to inherit from a core set of files on the file system, although appear to have unique pages, thereby increasing performance and allowing changes that happen to a site propagate to all sites that inherit from a site definition. Ghosted means that when SharePoint creates a new site it will reference the files in the related site definition upon site provisioning. Unghosted means that the site has been edited with an external editor, and therefore the customizations are instead stored in the database, breaking the inheritance of those files from the file system.

45) How does one deploy new SharePoint site definitions so that they are made aware to the SharePoint system?

The best way to deploy site definitions in the SharePoint 2007 framework is to use a SharePoint solution file, so that the new site definition is automatically populated to all WFE’s in the SharePoint farm.