How to deploy timer job in SharePoint 2010

Timer jobs are Microsoft.SharePoint.Administration.SPJobDefinition objects. To create a timer job, one should create a new class that inherits from SPJobDefinition. Timer jobs can be deployed by using Features, custom applications, Power Shell, or custom STSADM commands.

Debugging Types:
Debugging Timer Service: User needs to attach debugger with OWSTIMER.exe process. This is the “Windows SharePoint Services Timer" service.
Debugging Event Receiver: User can attach Visual Studio to the w3wp.exe process and simply put a breakpoint in the event handler code. Alternatively, use System.Diagnostics.Trace to write out information to a log.

Databases created at the time of installing SharePoint 2010

Secure Store database: The Secure Store service application database stores and maps credentials, such as account names and passwords. Prefixed with "Secure_Store_Service_DB_".
State database: The State service application database stores temporary state information for InfoPath Forms Services, the chart Web Part, and Visio Services. Prefixed with "StateService".
Web Analytics Staging database: The Staging database temporarily stores un-aggregated fact data, asset metadata, and queued batch data for the Web Analytics service application. Prefixed with "WebAnalyticsServiceApplication_StagingDB_"
Web Analytics Reporting database: The Reporting database stores aggregated standard report tables, fact data aggregated by groups of sites, date and asset metadata, and diagnostics information for the Web Analytics service application. Prefixed with "WebAnalyticsServiceApplication_ReportingDB_"
Search service application Administration database: The Administration database hosts the Search service application configuration and access control list (ACL), and best bets for the crawl component. This database is accessed for every user and administrative action. Prefixed with "Search_Service_Application_DB_".
Search service application Crawl database: The Crawl database stores the state of the crawled data and the crawl history. Prefixed with "Search_Service_Application_CrawlStoreDB_'.
Search service application Property database: The Property database stores information that is associated with the crawled data, including properties, history, and crawl queues. Prefixed with "Search_Service_Application_PropertyStoreDB_"
User Profile service application Profile database: The Profile database stores and manages users and associated information. It also stores information about a user's social network in addition to memberships in distribution lists and sites. Prefixed with "User Profile Service Application_ProfileDB_".
User Profile service application Synchronization database: The Synchronization database stores configuration and staging data for use when profile data is being synchronized with directory services such as Active Directory Prefixed with "User Profile Service Application_SyncDB_".
User Profile service application Social Tagging database: The Social Tagging database stores social tags and notes created by users, along with their respective URLs. Prefixed with "User Profile Service Application_SocialDB_".
Managed Metadata database: The Managed Metadata service application database stores managed metadata and syndicated content types. Prefixed with " Managed Metadata Service_".
Enterprise edition installation adds two more databases:
Performance Point service application database: The Performance Point service application database stores temporary objects, persisted filter values, and user comments. Name Prefix "PerformancePointServiceApplication_.”
Word Automation Services database: The Word Automation Services database stores information about pending and completed document conversions.Name Prefix "WordAutomationServices_..."

Appeal Soft SharePoint Interview Questions for 1 year experience

  • What is SharePoint Pillars ?
  • Difference between SharePoint 2010 and MOSS 2007 ?
  • What is Sandbox Solutions ? 
  • Variations in SharePoint 2010 ?
  • Explain the SharePoint 2010 services ? and how we can use in applications ?
  • SharePoint features ?
  • SharePoint Architecture ?
  • What is Object Model  in  SharePoint 2010 ?
  • Web-part deployment steps in SharePoint 2010 ? 
  • What is workflow ? 
  • How can we use different services in workflows ?
  • What are the SharePoint 2010 default workflows ?
  • Explain the different types of authentication and authorization in SharePoint 2010 ?
  • How to create Claim based authentication ?
  • How many types of databases in SharePoint 2010 ?
  • What is SPWeb and SPSite ? Where we can use ? How ?
  • What is Alternate Access Mapping in SharePoint 2010 ?
  • What is Threshold ?
  • What is List Size ? Maximum no of rows in a List ? 
  • Where SharePoint .dll's will saved in machine ?

How to Insert notepad data into CustomList In SharePoint 2010

            SPWeb web = new SPSite("http://demo:500/").OpenWeb();
            SPList empList = web.Lists["Dept"];
            SPListItem item;
            StreamReader sr = new StreamReader("C:\\a.txt");
            while (sr.Peek() != -1)
            {
                string record = sr.ReadLine();
                string[] data=record.Split(' ');
                item=empList.Items.Add();
                item["Title"]=data[0];
                item["DeptName"]=data[1];
                item["DeptId"]=data[2];
                item.Update();
            }
In Notepad:
1    IT     10
2   Gov   20
 

View Site Groups In SharePoint 2010

using (SPSite siteCollection = new SPSite("http://hrweb"))
 {
   using (SPWeb site = siteCollection.OpenWeb())
     {
       // Print all groups name of site
       foreach (SPGroup group in site.Groups)
       {
          Console.WriteLine(group.Name);
        }
      Console.WriteLine("View All Site Groups");
 }
}

Second highest Salary

Select MAX(Salary) from Emp where Salary <(Select MAX(Salary) from Emp)

Different Types of Authentication Architecture In SharePoint 2010

SharePoint 2010 web application in claims mode, different authentication options are available. These options determine the flow of the authentication process.

The steps in the authentication process. It explains, in order, the different routes that the authentication process flow can have, based on the authentication options that are available in SharePoint 2010.
Architecture of the Claims-Based Authentication:
















Steps in the Claims-Based Authentication Process:
  • The client requests a SharePoint resource.
  • As part of the request pipeline, if the request is not authenticated, the authentication components route the request based on the authentication settings for that zone.
  • The request is then processed by the authentication components. When more than one authentication method is configured for the given zone, the authentication selection page enables the user to choose the authentication method. If only one authentication method is specified, the request is processed directly by the specified authentication method.
  • The user is authenticated by the identity provider.
  • If authentication succeeds, the SharePoint security token service (STS) generates a claims-based token for the user with the information provided by the identity provider. If additional claims providers are configured, the STS augments the user's token with the claims given by the claims provider. 
  • The claims-based token of the user is sent back to the authentication components.
  • The authentication components redirect the request back to the resource address, with the claims-based token issued for the user.
  • The rest of the request pipeline is executed and a response is sent back to the requestor (client). As part of the request pipeline, the authorization is completed.
The flow of the authentication process is defined by the options that you select during the configuration of the zone.
Architecture of the Windows authentication:
The user selects the option that uses Windows authentication, the user request is redirected to the Windows authentication page, which is silent (no other UI is displayed to the user to indicate that the user is being redirected, unless basic authentication is configured). On the Windows authentication page, when the user is authenticated, a claims-based token is requested and the user is sent back to the requested resource. Because the request contains a claims-based token that was issued by SharePoint STS, a claims identity is created and the request process continues.

























Steps in the Windows Authentication Process:
  • The user requests a SharePoint 2010 resource.
  • User authentication (NTLM challenge/Kerberos negotiation) occurs.
  • The claims-based token request is sent to the SharePoint 2010 STS.
  • SharePoint STS gets the user's security groups from the Windows token and adds them as user claims in the token.
  • The claims-based token is issued.
  • The request is processed by the rest of the components in the pipeline.
  • The response is sent back to the user.
Architecture of the Forms-based Authentication:
The SharePoint forms-based login page collects the credentials of the user, which are then sent to the SharePoint 2010 STS. The STS calls the membership provider that is associated with that web application, to validate the user's credentials. If this succeeds, the STS retrieves the roles that the user belongs to and adds these as claims in the claims-based token that is sent back to the login page. From the login page, after the claims-based token is issued, the user is sent back to the request resource and the process continues in the same way as in Windows authentication.

























Steps in the Forms-based  Authentication Process:
  • The user requests a SharePoint 2010 resource.
  • SharePoint redirects the user to the forms-based authentication login page.
  • The username and password are collected from the user and sent to the SharePoint 2010 STS.
  • STS validates the user's credentials with the membership provider and, if validation succeeds, STS requests all the roles that the user belongs to and adds those claims to the user's token.
  • The SharePoint STS gets additional claims for the user (if an additional claims provider is registered for that web application/zone).
  • The claims-based token is issued to the user.
  • The request is processed by the rest of the components in the pipeline.
  • The response is sent back to the user.
Architecture of the SAML Token-Based Authentication:
Out-of-the box, with the default implementation of Active Directory Federation Services (AD FS), when SAML token-based authentication is enabled in the zone settings, users are redirected to a "silent" authentication page, which then redirects the user to the login page, as specified in the SAML-based authentication provider. After the user is authenticated by the authentication provider, a SAML token is issued, and the user is redirected back to the SharePoint 2010 SAML token–based authentication page. The SAML token is then included in the request with the redirect. This process is known as "passive profiles".
























Steps in the  SAML Token-Based Authentication Process:
  • The user requests a SharePoint 2010 resource.
  • SharePoint redirects the user to the SAML authentication page.
  • Based on the configuration of the trusted login provider, the request is redirected to the enterprise STS login page or to the federated STS login page.
  • The user provides credentials and STS issues a SAML claims-based token.
  • The external STS issues the user claims-based token.
  • A claims-based token for the user is requested from the SharePoint STS, and the token from the external STS is used as the authentication proof.
  • SharePoint STS gets additional claims for the user (if an additional claims provider is registered for that web application or zone).
  • SharePoint STS issues the claims-based token.
  • The request is processed by the rest of the components in the pipeline.
  • The response is sent back to the user.

SharePoint 2010 Out-of-the-Box Web Parts

SharePoint Server 2010 out-of-the-box Web parts, organized by categories.  Not all of these Web parts are available to every site.  Also note that lists or libraries created on the site will add new options to the "Lists and Libraries" category (hence the name).

List and Libraries

  • Announcements — Use this list to track upcoming events, status updates or other team news.
  • Calendar — Use the Calendar list to keep informed of upcoming meetings, deadlines, and other important events.
  • Links — Use the Links list for links to Web pages that your team members will find interesting or useful.
  • Shared Documents — Share a document with the team by adding it to this document library.
  • Site Assets — Use this library to store files which are included on pages within this site, such as images on Wiki pages.
  • Site Pages — Use this library to create and store pages on this site.
  • Tasks — Use the Tasks list to keep track of work that you or your team needs to complete.
  • Team Discussions — Use the Team Discussion list to hold newsgroup-style discussions on topics relevant to your team.

Business Data

  • Business Data Actions — Displays a list of actions from Business Data Connectivity.
  • Business Data Connectivity Filter — Filters the contents of Web Parts using a list of values from the Business Data Connectivity.
  • Business Data Item — Displays one item from a data source in Business Data Connectivity.
  • Business Data Item Builder — Creates a Business Data item from parameters in the query string and provides it to other Web Parts.
  • Business Data List — Displays a list of items from a data source in Business Data Connectivity.
  • Business Data Related List — Displays a list of items related to one or more parent items from a data source in Business Data Connectivity.
  • Chart Web Part — Helps you to visualize your data on SharePoint sites and portals.
  • Excel Web Access — Use the Excel Web Access Web Part to interact with an Excel workbook as a Web page.
  • Indicator Details — Displays the details of a single Status Indicator. Status Indicators display an important measure for an organization and may be obtained from other data sources including SharePoint lists, Excel workbooks, and SQL Server 2005 Analysis Services KPIs.
  • Status Lists — Shows a list of Status Indicators. Status Indicators display important measures for your organization, and show how your organization is performing with respect to your goals.
  • Visio Web Access — Enables viewing and refreshing of Visio Web Drawings.

Content Rollup

  • Categories — Displays categories from the Site Directory.
  • Content Query — Displays a dynamic view of content from your site.
  • Relevant Documents — Displays documents that are relevant to the current user.
  • RSS Viewer — Displays an RSS feed.
  • Site Aggregator — Displays sites of your choice.
  • Sites In Category — Displays sites from the Site Directory within a specific category.
  • Summary Links — Allows authors to create links that can be grouped and styled.
  • Table Of Contents — Displays the navigation hierarchy of your site.
  • Web Analytics web Part — Displays the most viewed content, most frequent search queries from a site, or most frequent search queries from a search center.
  • WSRP Viewer — Displays portlets from web sites using WSRP 1.1.
  • XML Viewer — Transforms XML data using XSL and shows the results.

Document Sets

  • Document Set Contents — Displays the contents of the Document Set.
  • Document Set Properties — Displays the properties of the Document Set.

Filters

  • Choice Filter — Filters the contents of Web Parts using a list of values entered by the page author.
  • Current User Filter — Filters the contents of Web Parts by using properties of the current user.
  • Date Filter — Filter the contents of Web Parts by allowing users to enter or pick a date.
  • Filter Actions — Use the Filter Actions Web Part when you have two or more filter Web Parts on one     Web Part Page, and you want to synchronize the display of the filter results.
  • Page Field Filter — Filters the contents of Web Parts using information about the current page.
  • Query String (URL) Filter — Filters the contents of Web Parts using values passed via the query string.
  • SharePoint List Filter — Filters the contents of Web Parts by using a list of values.
  • SQL Server Analysis Services Filter — Filters the contents of Web Parts using a list of values from SQL Server Analysis Services cubes.
  • Text Filter — Filters the contents of Web Parts by allowing users to enter a text value.

Forms

  • HTML Form Web Part — Connects simple form controls to other Web Parts.
  • InfoPath Form Web Part — Use this Web Part to display an InfoPath browser-enabled form.

Media and Content

  • Content Editor — Allows authors to enter rich text content.
  • Image Viewer — Displays a specified image.
  • Media Web Part — Use to embed media clips (video and audio) in a web page.
  • Page Viewer — Displays another Web page on this Web page. The other Web page is presented in an IFrame.
  • Picture Library Slideshow Web Part — Use to display a slideshow of images and photos from a picture library.
  • Silverlight Web part — A web part to display a Silverlight application.

Outlook Web App

  • My Calendar — Displays your calendar using Outlook Web Access for Microsoft Exchange Server 2003 or later.
  • My Contacts — Displays your contacts using Outlook Web Access for Microsoft Exchange Server 2003 or later.
  • My Inbox — Displays your inbox using Outlook Web Access for Microsoft Exchange Server 2003 or later.
  • My Mail Folder — Displays your mail folder using Outlook Web Access for Microsoft Exchange Server 2000.
  • My Tasks — Displays your tasks using Outlook Web Access for Microsoft Exchange Server 2003 or later.

PerformancePoint

  • PerformancePoint Filter — This web part displays PerformancePoint filters. Filters may be linked to other web parts to provide an interactive dashboard experience. Filter types include lists and trees based on a variety of data sources.
  • PerformancePoint Report — This web part displays PerformancePoint reports. Reports may be linked to other web parts to create an interactive dashboard experience. Report types include: Analytic charts & grids, Strategy Maps, Excel Services, Reporting Services, Predictive Trend charts, and web pages.
  • PerformancePoint Scorecard — This web part displays a PerformancePoint scorecard. Scorecards may be linked to other web parts, such as filters and reports, to create an interactive dashboard experience.
  • PerformancePoint Stack Selector — This web part displays a PerformancePoint Stack Selector. All PerformancePoint web parts, such as filters and reports, contained in the same zone will be automatically stacked and selectable using this web part.

Search

  • Advanced Search Box — Displays parameterized search options based on properties and combinations of words.
  • Dual Chinese Search — Used to search Dual Chinese document and items at the same time.
  • Federated Results — Displays search results from a configured location.
  • People Refinement Panel — This webpart helps the users to refine people search results.
  • People Search Box — Presents a search box that allows users to search for people.
  • People Search Core Results — Displays the people search results and the properties associated with them.
  • Refinement Panel — This webpart helps the users to refine search results.
  • Related Queries — This webpart displays related queries to a user query.
  • Search Action Link — Displays the search action links on the search results page.
  • Search Best Bet — Displays high-confidence results on a search results page.
  • Search Box — Displays a search box that allows users to search for information.
  • Search Core Results — Displays the search results and the properties associated with them.
  • Search Paging — Display links for navigating pages containing search results.
  • Search Statistics — Displays the search statistics such as the number of results shown on the current page, total number of results and time taken to perform the search.
  • Search Summary — Displays suggestions for current search query.
  • Search Visual Best Bet — Displays Visual Best Bet.
  • Top Federated Results — Displays the Top Federated result from the configured location.

Social Collaboration

  • Contact Details — Displays details about a contact for this page or site.
  • Note Board — Enable users to leave short, publicly-viewable notes about this page.
  • Organization Browser — This Web Part displays each person in the reporting chain in an interactive view optimized for browsing organization charts.
  • Site Users — Use the Site Users Web Part to see a list of the site users and their online status.
  • Tag Cloud — Displays the most popular subjects being tagged inside your organization.
  • User Tasks — Displays tasks that are assigned to the current user.
  • What’s New — This Web part shows new information from specified lists and libraries.
  • Whereabouts — Use to display Whereabouts information.

DataView WebPart In SharePoint 2010

A Data View Web part is a great way to display data with filtering, grouping, and user desired formatting.  It was the most useful webpart in SharePoint 2007 and now has been improved to a great extend in SharePoint 2010.  In SharePoint 2010 you now have a  XSLT Listview webpart and a Dataview webpart (Old one).
XSLT Listview webpart  – XSLT Listview webpart is a ListView whose XSLT can be modified in SharePoint designer.  With this you now have some advanced formatting options and can also use all the filters,sorting grouping etc features that a Dataview wbepart had in SharePoint 2007.
DataView Webpart – Even after all the great features that XSLT Listview webpart has offered, i would still prefer to work with the old Dataview webpart’s XSLT if i have to. The OLD dataview webpart is still available and can be used in the same manner as we used in SharePoint 2007. To add a Dataview webpart onto a page follow the steps below.
1. Open your SharePoint Page and in Site Actions select ->Edit in SharePoint Designer.
2. Now select a zone on teh Page where you want to add your Dataview weboart.
3. Next, click on Insert tab -> click on Data View.
4.  In the drop-down of Data view menu click on “Empty Data view” . This will now insert an Empty Data view in your selected zone.
5. Next click on “click here to select datasource” to select the datasource or list.
6. Select the list\library you want to display the data from.
7. Next drag and drop the columns in the dataview webpart from the right hand column list (for the list\library you selected).
You now have the Dataview webpart on your page. You can now use the formatting options available on your ribbon or can modify the XSLT either in Designer or on the page itself by editing the webpart properties in the Browser.

Different Types of WCF Hosting Environments

Self-Hosted:
By implementing your own self-hosted service application, you can:

  • Add code to start and stop your WCF service when required.
  • Expose your WCF service over protocols other than Hypertext Transfer Protocol (HTTP).
  • Add additional code to get state information about the service host.

Windows Services:
This hosting option works by registering the application as a managed Windows service. Because the operating system controls the lifetime of the service, you can activate and start your WCF service as soon as the system starts. After it has started, the service runs silently in the background. Like the self-hosting option, this type of hosting environment requires that some hosting code is written as part of the application
IIS:
The IIS hosting option enables:

  • Message-based activation, which creates a new instance of the service when a message arrives, rather than having a service running constantly.
  • Process recycling, which restarts the hosting process to clear the effects of memory leaks.
  • Idle shutdown, which stops and serializes the service after a given time to conserve system resources.
  • Process health monitoring, which enables you to respond to resource issues in the services.

WAS:
IIS 7.0 includes WAS. Hosting your WCF service in WAS offers all of the benefits of hosting in IIS, including:

  • Message-based activation
  • Process recycling
  • Idle shutdown
  • Process health monitoring

Additionally, WAS is a generalization of IIS that is not bound to HTTP.
For more information about the possible hosting options, see Hosting and Consuming WCF Services

Create a Sequential Workflow Using SharePoint Designer

Description:
       Here I created Leave application, where if required leaves is less than or equal to 1 means its "Automatically Approve", else its needs "Manager Approval".

In SharePoint 2010, first we need to create a custom list in my server(http://demo:500)
Here Select More Options, then












Here first select the Custom List, name it as "Leave Application" and click the create button,
Here, it will create a Custom List and default Title column and rename the title column to S.No.























Here, to click the Create Column for creating site columns.
























Here, create site columns Employee Name as Single line of text, Department as Choice are HR, ESD, Finance, StartDate as a Date filed, EndDate as a Date field and Required Leaves as number field.























Here, Our Leave Application List is look like as below























Now Here, List creation is completed now Open the SharePoint Designer























Here, select the workflows in that select the List Workflow and named it as Leave Application Status, give description also and click to ok button.























Here, Select the Condition in that select "If any value equals value" condition.























Step 1: Here, Take one If condition and set the parameters as Current Item:Required Leaves, operator is not equals to 1
Step 2: Here, In Action ribbon select "Start Approval process" and set the Approved.






















Step 3: Here, select the Wait for field in change in current Item and set the status as Pending.
Step 4: Here, take one more if condition and set the parameters as Current Item : Approval Status equals to select the Approver or Participants, enter title as a mandatory filed, add the participant and click to ok.
























Step 5: Here, If the Required Leaves are below 1 means automatically approved, that purpose in else block take the Set content approval status for this Document set to "Approved" with "Automatically Approved".























Here, finally workflow look like as below























Now finally save and  publish. Now go to the SharePoint server Leave Application List add new item to the list.























Now enter the appropriate values and click to save button.























Now Select the workflows


Now Start the Leave Application Status























Now click the Start button to start the workflow.










Here, workflow is started that why the workflow status it shows In Progress.























Here, Login to the Adam Barr, In that Task List it contain the details of the workflow.























Here, to enter the comments and click the Approve button.























Here, we can see the output of the workflow.
























Here, the required leaves are below 1 means automatically Leave Application Status it shows "Completed".
























Difference Between SharePoint Application Pages Vs Site Pages

Application Pages:
  • Application pages are stored in the server’s file system. 
  • SharePoint Designer tool cannot be used with application pages. 
  • Application pages cannot be used within sandboxed solutions. 
  • An Application page cannot be customized and modified by end user, instead a developer is required. 
  • These are the normal .aspx pages deployed within SharePoint. Most common of them are the admin pages found in _layouts folder.
  • These are deployed either at the farm level or at application level. If they are deployed within _layouts folder or global SharePoint Virtual Directory, then they can be used by any SharePoint application (available at farm level), otherwise they can be deployed at application level only by creating a virtual directory.
  • These are typical ASP.Net aspx pages and can utilize all of the functionalities available within ASP.Net including code-behind, code-beside, inline coding etc.
  • These are compiled by .Net runtime like normal pages.
  • If you deploy your custom ASPX pages within _layouts folder or within SharePoint application using a virtual directory, you will not be able to use SharePoint master pages and have to deploy your master page within the virtual directory or _layouts folder.
  • Application Pages cannot use contents as this concept is associated with SharePoint Page Layouts not with ASP.Net.
  • Since application pages are compiled once, they are much faster
  • Normally application pages are not web part pages, hence can only contain server controls or user controls and cannot be personalized by users.
  • Easiest way to deploy your existing ASP.Net web site within SharePoint is to deploy its pages as Application Pages within SharePoint. In this way you can convert any ASP.Net web solution as SharePoint application with minimal efforts.
  • SharePoint specific features like Information Management Policies, Workflows, auditing, security roles can only be defined against site pages not against application pages.
  • Application pages can be globalized using Resource files only. 
Site Pages:
  • Site Pages is a concept where complete or partial page is stored within content database and then actual page is parsed at runtime and delivered to end-users.
  • Site pages can be edited by using SharePoint Designer tool.
  • Site pages are used within Sandboxed solutions. 
  • A site page can be customized and modified by end user. 
  • Pages stored in Pages libraries or document libraries or at root level within SharePoint (Wiki pages) are Site Pages
  • You must be thinking why we should use such pages? There are many reasons for this. One of the biggest catch of the SharePoint is the page layouts, where you can modify page once for a specific content type and then you can create multiple pages using the same page layout with different contents. In this case, contents are stored within database for better manageability of data with all the advantages of a data driven system like searching, indexing, compression, etc and page layouts are stored on file system and final page is created by merging both of them and then the outcome is pared by SharePoint not compiled.
  • Site Pages can contain web parts as well as contents placeholders, and all of them are stored per page-instance level within database and then retrieved at run time, parsed and rendered.
  • Another advantage is they are at user-level not at web-application or farm level and can be customized per site level.
  • Since their definition is retrieved from database, they can utilize master pages stored within SharePoint masterpages library and merged with them at run time for rendering.
  • They are slower as compared to Application pages as they are parsed everytime they are accessed.
  • SharePoint specific features like Information Management Policies, Workflows, auditing, security roles can only be defined against site pages not against application pages.
  • Since they are rendered not compiled hence it is not easy to add any inline code, code behind or code beside. Best way of adding code to these pages is through web-parts, server controls in master pages, user controls stored in "Control Templates" folder or through smart parts. If you want to add any inline code to master page, first you need to add following configuration within web.config:<PageParserPaths>
            <PageParserPath VirtualPath="/_catalogs/masterpage/*" CompilationMode="Always" AllowServerSideScript="true" IncludeSubFolders="true" />
    </PageParserPaths>
  • To add code behind to SharePoint master pages or page layouts.
  • Since Site pages are content pages, hence all SharePoint specific features like Information Management Policies, Workflows, auditing, security roles can only be defined against site pages.
  • Variations can only be applied against Site pages for creating multilingual sites.
  • "SPVirtualPathProvider" is the virtual path provider responsible for handling all site pages requests. 

Differences between .NET vs. SharePoint?

Feature  
.NET
SharePoint
Creation:
Code need to be written even to achieve simple functionality
Lots of pre-defined web parts and elements available no need to write the code.
Time:
Takes time to create the code and test
Very less time required
Skilled Professionals:
Skilled professionals are required to create the functionality
Even novice professionals can do so easily
License Requirement:
Not required at the time of deployment of solution
Free versions available, but in case of extensive requirements License is required

SharePoint 2010 Basic Interview Questions and Answers

1.What is SharePoint 2010?
SharePoint was born out of a simple idea: “Sharing Documents”. Microsoft developed family of software products called “SharePoint”, to perform features like File Sharing, Collaboration, and Web Publishing. In simple terms, SharePoint acts as the single platform to share, communicate, store, and collaborate the content, documents, and records.
2.What does SharePoint 2010 family of products consists of?
  • SharePoint Foundation 2010
  • Search Server 2010 Express
  • SharePoint Server 2010
  • Search Server 2010
  • FAST™ Search Server 2010 for SharePoint
  • SharePoint Designer 2010
3.What are Features of SharePoint?
Communities: The new version of SharePoint allows users to work together in different ways. Microsoft has enhanced the social feature of SharePoint 2007 in SharePoint 2010 and has made it look better. Communities allow people to collaborate in groups, share knowledge, and find information on various topics easily.
Content: SharePoint content shifts SharePoint 2010 from a departmental solution to an enterprise solution. There has been massive improvement in content wherein users can add a significant number of documents to SharePoint. They can even use external data storage options to store more data.
Search: Microsoft SharePoint 2010 has acquired FAST search server, which improves the search tremendously for users. Now, users not only can search for content, but also people. User can opt for better language options with thumbnails and previews. User can even sort out the search queries and study similar search to get relevant search results.
Insights: with the help of SharePoint insights, users can access information through different data sources like dashboards, scorecards, reports and more. To help users, Microsoft has introduced performance point server to the SharePoint platform. It is also known as Performance point services for SharePoint. It helps users discover right people and expertise to make better business decisions.
Compositions: SharePoint being a complete platform helps users in creating their code solution on premises or in the cloud. Complex application can be developed with the help of well-known tools like:
  •  InfoPath
  •  SharePoint designer 2010
  •  Visio 2010
4. What are the new features in Sharepoint?
  • Access Services: Use Access Services in Microsoft SharePoint Server 2010 to edit, update, and create linked Microsoft Access 2010 databases that can be viewed and manipulated by using an Internet browser.
  • Business Connectivity Services: SharePoint Server 2010 include Microsoft Business Connectivity Services, which is a set of services and features that provide a way to connect SharePoint-based solutions to sources of external data and to define external content types based on that external data
  • Central Administration: Central Administration has been redesigned in SharePoint Server 2010 to provide a more familiar experience
  • Digital Asset Management: SharePoint Server 2010 includes a new asset library specially designed for managing and sharing digital assets such as audio, video, and other rich media files.
  • Enterprise Search (Fast Search): With the new capabilities in SharePoint Server 2010, search administrators can configure an optimal search infrastructure that helps end users find information in the enterprise quickly and efficiently.
  • Excel Services: Excel Services in SharePoint 2010 can be used to publish Excel client workbooks on SharePoint Server 2010
  • Health Monitoring: SharePoint Server 2010 includes an integrated health analysis tool called SharePoint Health Analyzer that enables SharePoint Server to automatically check for potential configuration, performance, and usage problems
  • Managed Metadata: The Managed Metadata Service supports the use of managed metadata, as well as the sharing of content types across the enterprise.
  • Performance Point Services: Performance Point Services in Microsoft SharePoint Server 2010 provides flexible, easy-to-use tools for building dashboards, scorecards, and key performance indicators (KPIs).
  • Records Management: In SharePoint Server 2010, user can manage records in an archive, or can manage records in the same document repository as active document
  • Sandboxed Solutions: User can deploy sandboxed solutions to quickly and more securely solve business problems. Sandboxed solutions are like farm solutions except in the following ways: they are rights-restricted and have a more permissive deployment policy than farm solutions; they are limited to the site collection to which they are deployed;
  • Social Computing: SharePoint Server 2010 includes social networking tools such as My Site Web sites and social content technologies such as blogs, wikis, and really simple syndication (RSS). These features are built upon a database of properties that integrates information about people from many kinds of business applications and directory services
  • Visual Upgrade: A new feature that is available with upgrade allows the server administrator or site owner to determine when and if the new look for SharePoint Server 2010 is used for a particular site collection. Server administrators can choose to adopt the new look and feel for all sites during upgrade, let site owners make the choice after upgrade, or keep the old look and feel for all site 
  • Feature Upgrade:SharePoint Foundation 2010 provides new members and types that make it possible for user to upgrade custom Features through versioning and declarative upgrade actions. User can update any Features created for Office SharePoint Server 2007 to work with SharePoint Server 2010 by using these members.
  • Visio Services: The Visio Graphics Service is a service on the SharePoint Server 2010 platform that enables users to share and view Visio diagrams and enables data-connected Microsoft Visio 2010 diagrams to be refreshed and updated from a variety of data source
  • Windows Power Shell: Windows Power Shell is the new command-line interface and scripting language specifically designed for Admin
  • Client Object Model: Microsoft SharePoint Foundation 2010 introduces three new client APIs for interacting with SharePoint sites: from a .NET managed application, from a Microsoft Silverlight or from ECMAScript (JavaScript, JScript) that executes in the browser. The new client object models provide an object-oriented system for interoperating with SharePoint data from a remote computer easier to use existing SharePoint Foundation Web services
5.What is Site collection?
SharePoint site collection is a logical grouping of multiple SharePoint site or hierarchical site structure. For e.g. Sites of various teams or departments of an organization can be grouped logically in one site collection. A site collection consists of a top-level site and one or more sites below it. Each top-level site and any sites below it in the site structure are based on a site template and can have other unique settings and content. Hence, SharePoint site collection is a hierarchical set of sites that can be managed together. Sites within a site collection have common features, such as shared permissions, galleries for templates, content types, and Web Parts, and they often share a common navigation. A sub site can inherit permissions and navigation structure from its parent site or these can be specified and managed independently. Creation of sub sites can be delegated to users of a site collection, but a service administrator must perform creation of site collections
6.What is Site?
Site is a collection of web pages used to store information in an organized manner. It stores a list of documents, discussions, events, tasks, and many other types of information. Site provides controlled access to share information among users, i.e. authorize users are allowed to access the site & its elements. User can configure following elements in SharePoint site:
  • Templates: Template acts as stencils, used to create similar attribute elements.
  • Language: SharePoint has ability to create multilingual sites. Language packs are installed on the server to translate the portal in other languages. User can select a language-specific site template while creating new site.
  • Security: User can define unique user groups and permissions for each site as well as site elements.
  • Navigation: Site navigation reflects the relationships among the sites in a site collection. User can fine-tune site's navigation experience by configuring unique navigation links in each part of site's hierarchy. Therefore, planning navigation and planning sites structures are closely related activities.
  • Web pages: Web pages in sites or site collection are used to display information.
  • Site layouts: Site Layout dictates the overall look and feel of the SharePoint site.
  • Themes: Themes specify the appearance of site in terms of Color & font.
  • Regional settings: Regional settings are specific to particular country or geography, such as locale, time zone, sort order, time format and calendar type.
  • Search: User can make each site having unique search settings. For example, user can specify that a particular site never appear in search results.
  • Content types: A content type defines the attributes of a list item, a document, or a folder.
  • Workflows: Workflow defines the action or series of actions that has to be performed on the occurrence of event.
7. What is Sub Site?
A sub-site is a single SharePoint site within a site collection. A sub-site can inherit permissions and navigation structure from its parent site or can be specified and managed independently.
8. What is List?
A SharePoint list is a collection of records related to an entity like a student, employees, etc. Records in lists are termed as items. A list contains columns or fields that define the item data or metadata. Lists are created using a GUI interface by defining the metadata types. Once the Lists are created, it becomes very easy to add, edit, delete, and search items in it.
9. What is Document Library?
A Document library allows users to easily store, upload, share, collaborate, and track documents or files. Users can also store the properties related to documents called metadata to make the documents easily searchable.
10. What is Picture library?
A Picture library allows users to easily store, upload, share, collaborate and track images or digital pictures. Users can also store the properties related to images called metadata to make the images easily searchable.
11. What is Check-out?
Check-out ensures that only one person can edit a document at a time. To edit a document, a user would first have to check out a document. This prevents anyone else from editing the document until that user check the document back in. During the period that the document is checked out, other users can only view a read-only version of the document.
12. What is Check-in?
Check in a file means that user is uploading the modified file to the library and it is now available for edit by other users. Once the document is checked in, the document becomes available again to be checked out by someone else. In addition, all changes made by the person who checked in the document are now visible to others.
13. What is Versioning?
Versioning allows updates, restoring and tracking of the items in a list or in a library when they are changed. Versioning makes use of version numbers to keep track of changes.
14. What is Site Columns?
A site column is a reusable column definition, or template that user can assign to multiple lists across multiple SharePoint sites. Site columns are useful if user organization wants to establish some consistent settings across lists and libraries.
15. What are the various built in columns available in SharePoint 2010?
  • Single line of text
  • Multiple lines of text
  • Choice (menu to choose from)
  • Number (1, 1.0, 100)
  • Currency ($, ¥, €)
  • Date and Time
  • Lookup (information already on this site)
  • Yes/No (check box)
  • Person or Group
  • Hyperlink or Picture
  • Calculated (calculation based on other columns)
  • Full HTML content with formatting and constraints for publishing
  • Image with formatting and constraints for publishing
  • Hyperlink with formatting and constraints for publishing
  • Summary Links data
  • Rich media data for publishing
  • Managed Metadata
16. What is Content Type?
A content type is a reusable collection of metadata (columns), workflow, behavior, and other settings for a category of items or documents. Content types enable user to manage the settings for a category of information in a centralized and reusable manner. A content type defines the attributes of a list item, a document, or a folder. Each content type can specify properties to associate with items of its type.
17. What is rating?
Rating provides user the ability to rate content (of any type, lists, documents, pages on a site, and even content types) and stores that rating information in the database. It is an assessment or classification of content on a scale according to how well the content meets specific criteria. Ratings show an average score that can range from 1 to 100.
18. What is Audience targeting?
The content inside lists, libraries, web parts, etc., can be targeted to appear only for the users who are members of a particular group or audience. The audience can be identified via SharePoint groups, distribution lists and security groups.
19. What are views?
User can use views to see the items in a list or library that are most important to user or that best fit a purpose. For example, user can create views of the files that were created most recently, of the list items that apply to a specific department, or of the files created by one person. After creating a view, it is always available when user looks at a list or library. User can create personal views and public views. A personal view is available only to user while looking at a list or library. A public view is available when anyone looks at a list or library. To create a public view, user must have permission to change the design of the list or library. User can make a public view the default view for a list or library.
20. What are the various types of views? 
  • Standard: This view displays list items or files like a traditional list on a Web page. Standard view is the default for most types of lists and libraries, and user can customize it in several different ways. 
  • Calendar: This view displays the calendar items in a visual format that is similar to a desk or wall calendar. User can apply daily, weekly, or monthly views in this format. For example, user can create a calendar to track the team's deadlines for a project or holidays for the organization. 
  • Datasheet: This view provides data in a format that user can edit, such as a table in a database or spreadsheet. This view can be helpful if user need to perform large editing tasks or customization, or export data to a spreadsheet or database program. Datasheet view requires a
control or program that is compatible with Windows SharePoint Services, such as Office Access 2007, and ActiveX control support.
  • Gantt: This view provides a visual view of data, with bars that track progress, if data is based on a time interval. A Gantt view can help user manage projects and see a quick overview of the data. User can use this view, for example, to see which tasks overlap each other and to visualize overall progress.
21. What is Task list?
A task list in SharePoint displays a collection of tasks that has to be performed. Users can also add columns or metadata to store additional information about the tasks.
22. What is Document Set?
 Document Set enables users to group multiple documents that support a single project or task, together into a single entity. All documents in a Document Set share the metadata and the entire set can be versioned. Document sets are built on SharePoint 2010 content types, and user can create multiple unique document set content types as part of their implementation.
24. What is Drop-Off Library?
The Drop Off Library will be the default destination when a user tries to upload a document to this site. This is used when user does not know that where should the document be uploaded in the site. In that case, user uploads the document in this library and the document is routed automatically to the specific library.
25. What is Routing Rules List?
The Routing Rules list, as its name implies, contains the rules for how a document is to be routed to its final destination. These rules are written to route the documents to their final and proper destination.
26. What is Blogs?
Blogs is a type of website, usually maintained by an individual with regular entries of commentary, description of events, or other material such as graphics or video. It can be used to post ideas, observations, thoughts and expertise on which comments can be done.
27. What is Enterprise wiki?
An enterprise wiki is a publishing site for sharing and updating large volumes of information across an enterprise. Enterprise wiki can be used as a central repository for large organizations to store and share unstated information.
28. What is Tagging?
Tagging is the ability to tag documents that enables user to search document easily with keywords. Tags cloud webparts enable users to display tagging keywords.
29. What is Recent activity?
The recent activity is a helpful way to understand what the person has been working on recently.
30. What is Survey?
Survey is used when user want to collect the responses from various people, across the organization about any event, any activity or any other thing. It is a list that allows user to collect the responses in various ways. User can ask the questions and they can answer those questions and then result can be analyzed by taking it to the excel sheet or through graphical summary or by watching all responses at once.
31. What is My site?
My Site is the individual mini sites and acts as a central location to view and manage all of a user’s documents, tasks, etc. My Sites enables users to easily share information about themselves and their work. This sharing of information encourages collaboration, builds and promotes information about expertise, and targets relevant content to the people who are interested.
32. What is enterprise Metadata Management?
Enterprise metadata management (EMM) is a set of features introduced in Microsoft SharePoint Server 2010 that enable taxonomists, librarians, and administrators to create and manage terms and sets of terms across the enterprise.
There are two key principles in the use of metadata:
  • Use of tags: It is easy for a site to use enterprise wide tags and taxonomies, and easy for users to apply them.
  • Application of tags in SharePoint 2010: The document libraries are configured to use metadata as a primary navigation pivot and improves search.
33. What is Web part?
Web Parts are customizable plug and play components that empower information workers to create personalized user interfaces by simply dragging and dropping them on a Web page. Web parts allow customization at both design time and run time. There are two types of web parts.
  • In-built web parts: Web parts that are included in SharePoint. Developers can drag them from web part galleries and drop them into web part zones.
  • Custom web parts: Web parts that are created by the user using visual studio is called custom web parts.
A Web Part is composed of the following entities:
  • The Web Part description file (.dwp) is a portable container of default and personalized property values for the Web Part.
  • The Web Part assembly file (.dll) contains the logic and code for the Web Part, and is installed on the server running Windows SharePoint Services.
  • Resource files that support the Web Part these are also stored on the server.
  • Tables in the Windows SharePoint Services database are used to store current values of the Web Part properties.
34. What is RSS Viewer?
RSS viewer is a web part that provides a good way of adding interesting content to SharePoint site pages.
35. What is a Record Center?
The Records Center is intended to serve as a central repository in which an organization can store and manage all of its records such as legal or financial documents. The Records Center supports the entire records management process, from records collection through records management to records disposition. The Records Center site template is a pre-configured site designed specifically to help organizations implement their records management and retention programs. Versioning, auditing, metadata management, eDiscovery, and customizable record routing are built-in features that can help user to manage records more effectively.
36. What is Document Center?
Document Center is a site on which user can centrally manage documents in an enterprise. A large-scale library useful as an enterprise knowledge base or historical archive includes features to help users navigate, search, and manage many documents in a deep hierarchy by using a set of specialized Web Parts.
37. What is Digital asset management?
SharePoint server 2010 includes a new asset library specially designed for managing and sharing digital assets such as audio, video, and other rich media files known as Digital Asset Management.
38. What is Social networking?
Social Networking Connects public to MySite pages to help establish connections between colleagues with common interests.
39. What is a recycle bin in SharePoint?
Whenever user will delete something, it goes to recycle bin in SharePoint. User can restore items that have been deleted from the site from the recycle bin.
40. What is Publishing feature?
Publishing feature enables the delivery of content for both internal and external users. User need to turn on the Publishing feature on a site. Checked in and Checked Out feature in a Site gets enabled and if user don’t Checked-in the change version then older version of pages are shown to users .Users can then brand the site so that it has the corporate look and feel, and can enable other users to edit the corporate site within the context of the Web. On a site with the Publishing functionality turned on, user can also create a multilingual site by creating a source site and then translating the site into other languages, which can be published as separate sites.
41. What is Branding?
Branding means to create and design the portal according to the organizational norms, by changing the title, logo, header, footer, and content to provide the look and feel that suite the organization. Creating custom-designed UIs, either on a traditional HTML page or in Microsoft SharePoint Server 2010, is known as branding. Branding of portals is done to achieve the unique corporate identity of an organization across the market.
42. What are Master page?
Master pages are template that other pages can inherit from to keep consistent functionality. The pages that inherit from master pages are referred to as content pages. Master pages allow developers to keep consistent, reusable, web based code (html, CSS, JavaScript, etc.) at one high level place, so that the content pages can concentrate on their specific web based code. A content page refers to a master page and the ASP. Net framework merges the two pages together to make one page.
43. What are the various types of master pages?
There are three types of master pages in SharePoint 2010
  • V4.master: Default team site master page. Provides ribbon bar and other editing features using UI.
  • Default.master: Sites upgraded from SharePoint 2007 use this unless they are changed to use a v4 version.
  • Minimal.master: These trimmed-down custom master pages are commonly referred to as Starter Master Pages in SharePoint 2010.
44. What are Content pages?
Content pages implement a master page. Content pages contain an attribute, which informs the compiler that the page should be, merged with a master page. This attribute is part of the page directive tag called the MasterPageFile.
45. What is Page Layout?
Page layout dictates the overall look and feel of a web page. A page layout relies on a content type to determine the kind of content that can be stored on pages. Page layout contains field controls and web part.
46. What is Site definition?
Site definitions are the foundations on which all sites and user templates are built. These are the collection of XML or ASPX files. Site definition contains information of web parts, lists, libraries, features, and navigation bars to be included in the site.
47.What is ONET.xml?
ONET.xml file is present in TEMPLATE\SiteTemplates\XML\Onet.xml location, which defines the setup of the site definition, such as which Features to load, where the web parts go and what they will perform and which document library templates to assign and many more.
48. List all the types of custom templates in SharePoint 2010?
Custom templates are of four types:
  • List Templates: List templates contain the files, views, fields, Web Parts, and, optionally, the content that is associated with a list. Users create list templates on the Save as Template page for a list or through code, that uses the SaveAsTemplate method of the SPList class. When saved, list templates are stored in the List Template Gallery of the top-level site in a site collection, where they become available to all sites in the site collection that derive from the same site definition and language as the site on which the list was originally created
  • Library Templates: A library template contains several types of libraries like asset library, document library, form library, record library, picture library, wiki page library. Each type of library displays a list of files and key information about the files, such as who was the last person to modify the file, which helps people to use the files to work together.
  • Page Templates: Page template contains web part page, publishing page, and a normal html page. These templates are easily customizable and are used for sharing content.
  • Site Templates: Site templates contain the same type of data as list templates, but site templates include data for the entire site. Like list templates, site templates may also include the content of the site.
49. What is Theme?
SharePoint theme represents a collection of graphics and cascading style sheets that can modify how a website looks. Using themes, we can change font and color scheme of the sites.
50. What is Navigation in SharePoint 2010? 
Site navigation provides the primary interface for site users to move around on the sites and pages on the site. Microsoft SharePoint Server 2010 includes a set of customizable and extensible navigation features that help orient users of the site so they can move around on its sites and pages.
51. What are the various options for Navigation available in SharePoint 2010? 
1. Navigation controls on master pages
  •  Top link bar navigation 
  •  Quick Launch navigation 
  •  Breadcrumb navigation 
  •  Tree view navigation 
  •  Metadata navigation 
2. Navigation controls on page layouts 
  • Summary Links 
  • Table of Contents 
  • Content Query 
3. Navigation Web Parts
  • Categories 
  • Site Aggregator 
  • Site in Category 
  • Tag Cloud 
The following navigation Web parts are available only on
4.Publishing sites:
  • Summary Links 
  • Table of Contents
52. What is Ribbon interface?
Ribbon Interface act as the UI enhancement in the product. It provides the commands to be executed in the form of Icons and tabs.
53. What is a workflow?
A workflow consists of a sequence of connected steps. It is a depiction of a sequence of operations, declared as work of a person, a group of persons, an organization of staff, or one or more simple or complex mechanisms.
54. Explain .Net Workflow and SharePoint workflow?
  • .Net Workflow: Windows Workflow Foundation (WWF) is a new programming framework introduced in .NET 3.0 for creating reactive programs. A reactive program typically represents a set of procedures or instructions used to capture and automate a specific business process. Windows Workflow Foundation supports publishing a workflow as an ASP.NET Web service on a Web server or server farm running ASP.NET on Internet Information Services (IIS) 6.0. Because Windows Workflow Foundation Web service support is based on ASP.NET 2.0, it inherits most of the features of a standard ASP.NET Web service.
  • SharePoint Workflow: SharePoint workflows are built on top of WWF. WSS extends the WWF. WSS extends the WWF by introducing the concept of a workflow template. The main purpose of the workflow template is to integrate WWF programs into WSS so that they can be installed, configured and parameterized for use. A workflow template is created by adding a Workflow element to a feature that is scoped to the level of the site collection.
55. What is Single sign-on?
Single Sign-on allows users to log on to a variety of applications with the single username and password and user has to enter the details only once for all the applications.
56. What is ULS Logging?
ULS Logging captures and writes events to trace logs.
57.What are the key differences between Site template and site definition?
Site Definitions
Site Templates
Site Definitions are the foundations on which all sites and user templates are built. Site Definition is collection ox XML and .aspx file. Site Definitions are predefined components needs to be included when a site was created in SharePoint server. Site Definition contains information of Web Part , Lists, Features and navigation bars to be included in the site
Site template approach for SharePoint Site Creation is easier, and just requires the use of the Web interface and occasionally Microsoft FrontPage. Content can be saved with site template
Files are on disk, better performance.
Files are in content database, less efficient.
Highly customizable and extensible (XML and .NET code is much more flexible than UI)
Not easily extensible (users are limited by what UI offers)
Can provision multiple webs
Can only provision one web


























58.What is Sandbox solution?
When user writes custom code, the code is not trusted, its failure can influence entire site. So the sandbox solution concept is used. In that case, program is only written for particular site & solution is uploaded in the same site. The solution size limit is decided at the time of site creation & if size increases or code shows bad performance then it will be easy for the administrator to stop the working of solution.
59. What can be deployed as a Sandbox solution in SharePoint 2010?
Users can deploy the below four things as sandboxed solutions:
  • WebParts.
  • Event Receivers.
  • List Definitions.
  • Workflows.
60.What is SharePoint Designer?
SharePoint Designer is a specialized HTML editor and web design freeware for creating and modifying Microsoft SharePoint sites and web pages. It is a part of Microsoft SharePoint family products.
61. How does Client object model works?
When developer use SharePoint client API’s to perform a specific task, the SharePoint 2010 managed client object model bundles up these uses of the API into XML and sends it to the server that runs SharePoint Foundation. The server receives this request, and makes appropriate calls into the object model on the server, collects the responses, forms them into JavaScript Object Notation (JSON), and sends that JSON back to the SharePoint Foundation 2010 managed client object model. The client object model parses the JSON and presents the results to the application as .NET Framework objects (or ECMAScript objects for ECMAScript).
62.What are the Authentication methods for the client object model application? 
A developer can use three authentication options while working with the Client Object Model in SharePoint 2010: 
  • Anonymous
  • Default 
  • FormsAuthentication 
63. How can a developer write efficient and better performing client object applications? 
Developer can always use Lambda expressions in their queries to return only specific properties that will be used in the block. Developer can also use LoadQuery() method and specify multiple levels of properties to load for e.g. while returning specific properties of the lists using LoadQuery(), developer can also specify the fields to return from each list to optimize the data access.
64. What is difference between Load() and LoadQuery() methods?
Load method populates the client object directly with what it gets data from the server i.e. a collection object like ListItemCollection etc. but LoadQuery returns the data as a completely new collection in IEnumerable format. Other major difference is that the Collections that user load using the Load() method are eligible for garbage collection only when the client context variable itself goes out of scope whereas, in these collections go out of scope at the end of IEnumerable<List> list.
65. What is the purpose of calling clientContext.ExecuteQuery()? 
ExecuteQuery gives developer the option to minimize the number of roundtrips to the server from the client code. All the components loaded into the clientcontext are executed in one go. 
66. What is the GAC?
 Global Assembly Cache folder on the server hosting SharePoint. Users place their assemblies here for web parts and services. 
67. What is CAML? 
CAML stands for Collaborative Application Markup Language and is an XML-based language that is used in Microsoft Windows SharePoint Services to define sites and lists, including, for example, fields, views, or forms, but CAML is used to define tables in the Windows SharePoint Services database during site provisioning. 
68. Why would a developer use LINQ over CAML for data retrieval? 
Unlike CAML, with LINQ to SharePoint provider, developers are working with strongly typed list item objects. For example, an item in the Announcements list is an object of type Announcement and an item on a Tasks list is an object of type Task. Developer can then enumerate the objects and get the properties for their use. In addition, developer can take benefit of LINQ syntax and the LINQ keywords built into C# and VB for LINQ queries.
69. What are the Disadvantages of Using LINQ in the Code?
 LINQ translates the LINQ queries into Collaborative Application Markup Language (CAML) queries thus adding an extra step for retrieving the items.
70. What does AllowUnsafeUpdates do?
If developer is trying to modify Windows SharePoint Services data using code, developer may need to allow unsafe updates on the Web site, without requiring a security validation. For this, developer needs to set AllowUnsafeUpdates property to true. 
71. What does RunWithElevatedPrivileges do? 
There are certain object models that call another model that require site-administration privileges. To bypass access-denied error, we use RunWithElevatedPrivileges property when a nonprivileged user initiates request. We can successfully make calls into the object model by calling the RunWithElevatedPrivileges method provided by the SPSecurity class.
72. How is a Content Type created?
We can create column and content types in three ways:
  • Using the SharePoint Foundation user interface.
  • Using the SharePoint Foundation object model.
  • Deploying a Feature that installs the content type based on an XML definition file.
73. How is a Content type deployed?
Content Type can be deployed and associated with list using feature. Inside the Feature, the feature.xml file contains references to all the element manifests within that Feature. Content type definitions are element manifests.
74. What is the scope of a content type?
A site content type becomes available to lists and document libraries within the site in which the content type is created and to the lists and document libraries in any child site.
75. 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.
76. What is ghosted page and Un-ghosted page ? 
  • ghosted page: is a page in SharePoint website which is not stored in the database instead it reference to a file which exists in the server’s file system. These reference files are common for all the website/site collection within that SharePoint server, i.e., if user modify a reference file then that change will reflect in all the websites/site collections within that SharePoint server automatically.
  • Un-ghosted page: changes done in an un-ghosted page will not reflect in other websites within that SharePoint server.
77.Can web parts and web zones be added to an Application page? 
No, since Application pages does not support edit mode so web part zones and web parts cannot be added using SharePoint. However, static web parts can be added by editing then in Visual Studio, as web parts are nothing but controls with some extra functionality. 
78.How to create a custom master page?
There are multiple ways to create custom master page files
  • By copying and editing existing master page.
  • By SharePoint Designer.
  • By editing minimal.master using editor.
79. How to apply a custom master page?
There are two ways to apply a custom master page
1. Custom Master Page can be deployed using SharePoint Feature by which master page gets uploaded to the master page gallery.
2. Custom master page can be uploaded directly in master page gallery library and apply the same master page using site and system master page option in Site Settings page by selecting Master Page option.
80. Can developer use the custom master page with the application pages in SharePoint 2010? 
With 2010, developer can now set whether the pages under _Layouts use the same Master Page as the rest of the site. Developer can enable or disable this functionality through the web application settings in Central Administration. This however, is not applicable to the custom application pages. If developer wants the custom application page to inherit the site master page, he must derive it from Microsoft.SharePoint.WebControls.LayoutsPageBase class.
81. How to link the custom CSS file in the master page?
Custom CSS files can be linked to the master pages with the help of a class called Sharepoint:CssRegistration.
82. What is the best method on working with CSS?
The best method to work with css is to create a new css file, store the file in any document library, and then provide the alternate CSS URL to the site by navigating to the master page option in the Look and Feel.
83. If a developer creates a new CSS file then where should the file be stored?
The css file can be stored in two locations, either in the document library or in the layouts folder.
84. How will user deploy a CSS file in SharePoint 2010?
The most preferable way to deploy files in SharePoint is by using the solution package. In SharePoint 2010, developer can create an empty project with VS 2010 and then add a new SharePoint Mapped folder in it. This will give the desired location in 14 hive where developer can then add a file to deploy.
85. If multiple css files are used in the same master page then how can a developer order the files to be applied to the master page?
The ordering of the css files can be done with the help of the CssRegistration class. Suppose if there are four css files to be linked namely 1.css, 2.css, 3.css and 4.css then the “after” attribute of the CssRegistration class can be used. Firstly, apply 1.css and use after attribute with value Corev4.css and then link 2.css file and use after attribute with value 1.css and so on.
86. How to create custom Themes?
Custom themes can be created for SharePoint by two ways.
  • Creating a theme in Microsoft PowerPoint.
  • Themes can also be created with the help of Visual Studio.
87. What does safe control means?
SharePoint application runs in Full Trust mode. For Web Parts to work properly in SharePoint Sites, its entry in web.config file assures Full Trust to SharePoint Site as it is registered in the file as safe.
88. What is User Control and how to use in SharePoint 2010?
User controls are created using a designer’s tool, having file extension as “.ascx”. User controls cannot be shared across web applications.
Suppose there is a user control MyControl.ascx. This file has to be deployed to the SharePoint server along with its binary. If developer is using a Smart Part, the ascx file must be copied to a folder called User Controls located in the root of the web sites folder (by default c:\inetpub\wwwroot\wss\VirtualDirectories\80. I recommend creating of own web part to host the user control that will work with any application. SharePoint itself puts all user controls in the TEMPLATES folder in the 14 hive (C:\Program Files\Common Files\Microsoft shared\Web Server Extensions\14).
89. How can a user add content to the content editor web part?
There are three ways to add content to the content editor web part.
  • Rich Text Editor: It allows user to add formatted text automatically without prior knowledge of HTML syntax.
  • Source Editor: The source editor is a plain text editor and it is intended for users who are familiar with HTML syntax. It allows user to add scripts, HTML and styles to a web part page.
  • Content link: It is used to link existing content by entering a hyperlink to a text file that contains HTML source code.
90. What is Content query web part?
Content query web part displays a dynamic set of items based on a query that user build by using a web browser. The query displays selected items. User can set presentation options to determine how these items are displayed on the finished page.
91. How to deploy a web part?
We can deploy a web part using three methods
1. Using Feature
2. Using Windows PowerShell.
ex: (PS C:\>) Install -SPWebPartPack -LiteralPath “FullPathofCabFile” -Name “Name of WebPart”.
92. Can a modal dialog be displayed from a webpart? 
Yes, a modal dialog can be displayed from within a webpart code since it is a JavaScript block that can be registered on the page.
93. While creating a Web part, which is the ideal location to initialize the web controls? 
Override the CreateChildControls() method to include web controls. Developer can control the exact rendering of the controls by calling the Render method.
94. What is SharePoint designer workflow?
One of the most powerful features of SharePoint designer is the ability for non-programmers to easily create business tailored workflow to improve business process management. SharePoint designer workflow is an easy, cheap, and somewhat limited entry point to workflow development. They are easy because most end users and administrators can become workflow developers without too much training.
95. Can Developer modify the Out-of-Box workflows in SharePoint 2010?
In SharePoint 2010, developer has an option to customize the Out-of-Box workflows. The four most popular workflows in SharePoint Server 2010 — the Approval, Collect Feedback, Collect Signatures, Publishing Approval workflows — have been completely rebuilt as declarative reusable workflows, meaning that they are now fully customizable in SharePoint Designer 2010.
96. When is workflow forms created? And how to customize it?
SharePoint Designer 2010 automatically generates the forms, but user can customize them by going to the settings page for the workflow, in the Forms section, click the form user want to customize. Workflow forms are either InfoPath or ASP.NET pages. They are stored on the SharePoint site with the workflow source files.
97. Where are the InfoPath forms published in SharePoint?
InfoPath forms are published in the Manage Form Template in Central Administration site or to a list or a form library in a site collection.
98. What is the scope of feature activation?
Feature can be activated or deactivated at various scopes throughout a SharePoint instances, such as farm level, web application level, site collection level, web level, etc.
99. What is the difference between feature definition and feature instance?
The feature definition is the set of source files in the Visual Studio 2010 project that is deployed using a solution package. Once deployed, a feature definition is a set of template files and components that reside on each front-end Web server. A feature instance is what is created when a user activates the feature definition.
100. What are the minimum files required for a feature?
Every feature directory should contain at least one file namely feature.xml and should be placed in the root of the directory. But a feature directory can contain one or more xml files as well as resource files such as image files, css files or js files. A feature.xml file contains attributes like Id, Title, Description, Version, Scope, Hidden, and ImageURL.
101. What is hidden attribute in a feature?
Hidden attribute will take the value of True or False. If it is set to False, after installation the feature definition can be seen by administrators only.
102. What is Elements.xml file in Feature in SharePoint 2010?
Elements.xml file contains the actual feature element. It can contain elements like ListInstance, Field, ContentType, ListTemplate, Workflow, WorkflowActions etc.
103. What is Feature Receiver in SharePoint 2010, its base class along with the methods that needs to be override?
A Feature Receiver allows user to write event handlers in a managed programming language such as C# or Visual Basic. These event handlers are executed during feature specific events such as feature activation and feature deactivation. The base class is SPFeatureReceiver. The methods to be overridden are: FeatureActivating, FeatureActivated, FeatureDeactivating,FeatureDeactivated etc.
104. How are features created?
Feature can be created by creating a new Empty SharePoint project from VS 2010 and then add new item named feature. After user has created the project, right click on the "Features" node in "solution explorer" and "add feature". This will create a new feature with the title "Feature1". User can rename it or leave it as it is. On double clicking the name of the feature, the properties of the feature will appear, such as title, description and the scope. Right click on the "feature1" in solution explorer and click on "Add feature Receiver" to add it. After the file has been created, uncomment (as required) the "on activate" and/or “on deactivate" and put code in there.
105. What is a Manifest.xml File in SharePoint 2010?
Manifest.xml file contains the Meta data of a solution package. At the time of deployment, SharePoint inspects manifest.xml file to determine which template files it needs to copy into the SharePoint root directory.
106. What is New in SPALerts?
In SharePoint 2007, alerts were sent only through e-mails, but in SharePoint 2010, users can also send an alert to mobile devices as SMS Message. A New property DeliveryChannels is introduced to indicate, whether the alert is delivered as E-mail or as an SMS Message.
107. What is Claims based authentication?
Claims based authentication provides a new authentication model that supports any corporate identity system like active directory domain services, LDAP-based directories, application-specific databases, etc.
The purpose of claims-based authentication is to make authentication simple for all users. For example, user may want to setup a SharePoint site that is accessible by both internal and external users, such as clients. Internal users might use one mechanism such as Windows-based authentication and external users might want to use another method, such as forms-based authentication. No matter what authentication protocol was used, the SharePoint application gets a signed set of claims so it has the information it needs about the user.
108. What is Classic-mode authentication?
In the classic authentication mode, only mixed-mode authentication is available. In mixed-mode authentication, a single SharePoint web application has to be extended to additional IIS applications with different URLs and authentication providers. The same content is used for the different URLs, but the different authentication providers can change the access users have, and their permissions.
109. What is Content Editor Web part?
Content Editor Web part is a universal plug in adapter. It is used to connect SharePoint pages to the rest of the world. User can use content editor web part to add html/CSS/JavaScript, embed videos or widgets, formatted text, tables, hyperlinks, images, and display content from other SharePoint sites to a web part page.

110.What is the directory structure created during SharePoint installation?
The directory created while installing SharePoint 2010 is
C:\Program Files\Common Files\Microsoft Shared\web server extension\14
  • ADMISAPI
  • BIN
  • CONFIG
  • HCCab
  • Help
  • ISAPI
  • LOGS
  • Policy
  • Resources
  • TEMPLATE – Sub Directories (1033, Admin, FEATURES, LAYOUTS, IMAGES, PAGES, Themes, SQL, XML, ControlTemplates, Document templates, IDENTITYMODEL, Site Template, GLOBAL).
  • UserCode
  • WebClients
  • WebServices
111. What has Changed in SharePoint 2010 Object model? 
Microsoft has replaced the “12 hive” structure that we had in SharePoint 2007 with “14 Hive” structure in 2010. It has apparently added four new folders to its hive. The Folders are:
  • Policy 
  • UserCode 
  • WebClients 
  • WebServices