Posts

Showing posts from 2013

Steps to use LINQ in SharePoint

In order to use LINQ in SharePoint, firstly we need to create a Data Context class. The steps to be followed are as follows: Open up the SharePoint Management Shell and give the command SPMETAL /web:<url of the web site> /code:<the name of the class file> Once the file has been generated add the same to the project where it needs to be used We need to add a reference to the class "Microsoft.SharePoint.Linq" In the Visual Web Part class where we need to use the LINQ we need to add a reference to the "Microsoft.SharePoint.Linq" and "System.Linq" We need to then create an object of the Data Context class created and use the same for CRUD operations

What is the difference between ExecuteNonQuery, ExecuteScalar and ExecuteReader?

All these methods are used to manipulate or retrieve data from the database. The details are as folllows: ExecuteNonQuery The method executes a transaction (Insert/Update/Delete) and returns the number of rows affected, in addition if there are triggers associated with the table the number of rows affected by that will also be returned. ExecuteSclar The methods only returns the value from the first cell of the first row, this is used for commands like COUNT etc which returns a single value. ExecuteReader This method is used to read data from the table and return the same, the return value creates a SQLDataReader object.

Explain normalization in SQL Server

Normalization is the process of organizing data into a related table; it also eliminates redundancy and increases the integrity which improves performance of the query. Database normalization can essentially be defined as the practice of optimizing table structures. Optimization is accomplished as a result of a thorough investigation of the various pieces of data that will be stored within the database, in particular concentrating upon how this data is interrelated. Normalization avoids: Avoids Duplicates - it makes sure that duplicate data is not stored Insert Anomaly - A record about an entity cannot be inserted into the table without first inserting information about another entity - Cannot enter a customer without a sales order Update Anomaly - Cannot update information without changing information in many places. To update customer information, it must be updated for each sales order the customer has placed Delete Anomaly - A record cannot be deleted without d...

Explaing locking in SQL Server

In SQL Server locking can be done at various levels, the levels are as follows: RID - this is used to lock a single row Key - this is used to lock rows within an index Page - this is used to lock a 8 KB data page or index page Extent - this is used to lock contiguous 8 data pages or index pages Table - this is used to lock a table including the data and index Database - this is used to lock the full database The various types of locking that are available are as follows: Shared Lock (S) Shared lock is used for concurrent read operations (SELECT), once the read operation is done the lock is released unless the lock has been specified as a repeated process or a locking hint has been used to keep the lock till the duration of the transaction. Update Lock (U) This type of lock is used on resources that can be updated and prevents the common type of deadlock where by two transactions are trying to update at the same time. Only one transaction can obtain an Update lock, if any ...

What is the difference between DDL, DML and DCL?

Data Definition Language (DDL) There are called data definition cause they define the data Create - creates objects in the database Alter - alters objects in the database Drop - deletes objects in the database Truncate - deletes all records from the table along with the space Rename - renames objects in the database Data Manipulation Language (DML) These are used for data manipulation Select - selects records from the table Insert - create a new record in the table Update - updates the records in the table Delete - deletes all the records in the table, but the space remains Lock Table - locks a table for controlling data concurrency Data Control Language (DCL) This is used to control the data, that the data that can be accessed by the user based on his privilege Grant - grants users access to the database Revoke - removes the access of the user to the database Transaction Control Language (TCL) This is used to control the changes done by the DML statemets C...

What is a Static method?

Static methods are those which can be called from another class without instantiating an object of the class where it has been declared. It can be called directly after the class name for e.g. classname.staticmethod A static method is declared by using the keyword 'static'

What is Polymorphism?

By Polymorphism we mean one state having different forms, polymorphism is implemented by the use of method overloading or overriding. Polymorphism is of two types which are as follows: Compile Type Polymorphism or Early Binding or Static Binding This is the process whereby the compiler already identifies which method to execute at the compilation time itself. The main advantage is that the execution is much faster and the disadvantage is that it is not flexible. Examples: Method Overloading or Overriding Run Time Polymorphism or Late Binding or Dynamic Binding This is the process whereby he compiler identifies which method to execute at runtime. The main advantage is that it is flexible and the disadvantage is that the execution speed is much slow. Examples: Overridden Methods which are using the base class object

What is Inheritance?

Inheritance is a relationship between classes where one class is the parent/super class of another. Classes can inherit from another class only, it cannot inherit from multiple classes but can inherit from multiple Interfaces. This is accomplished by putting a colon after the class name when declaring the class and naming the class to inherit from—the base class—after the colon. The different types of inheritance that are there are as follows: Single Inheritance In this type one child class is created from one base class Hierarchical Inheritance In this type more than one child class is created from a single base class Multi-Level Inheritance In this type one child class is derived from a class which is derived from another base class Hybrid Inheritance This type is a combination of Single, Multi-level and Hierarchical inheritance Multiple Inheritance This type is not supported by C# where a class is derived from multiple base classes, but a class can be derived from one bas...

What is an Abstract Class?

An abstract class is a special class which cannot be instantiated but it needs to be implemented in the sub class. The methods declared within the class needs to be implemented (in the abstract class we only have the declaration for the method) in the sub class using the " override " keyword. The abstract class or method declared needs to have the keyword " abstract ". An abstract class can inherit from a class and one or more interfaces An abstract class can implement code with non-Abstract methods An Abstract class can have modifiers for methods, properties etc An Abstract class can have constants and fields An abstract class can implement a property An abstract class can have constructors or destructors An abstract class cannot be inherited from by structures An abstract class cannot support multiple inheritance  Reference: http://www.c-sharpcorner.com/uploadfile/annathurai/abstract-class-in-C-Sharp/ http://www.codepr...

What is Method Hiding?

If methods are declared in a child and base class with the same signature but without the keywords virtual and override , the child class function is said to hide the base class function. The method in the child class is denoted with the New keyword. For e.g. public class VirtualDemo {     public void Hello ()     {         Console.WriteLine("Hello in Base Class");     } } public class A : VirtualDemo {    public new void Hello ()    {       Console.WriteLine("Hello in Derived Class");    } }

What is Method Overriding?

Method Overriding is a process by which the abstract methods that are declared in the abstract class are implemented in the child class, that is the class where the abstract class is inherited. The method should be preceded by the keyword " override " or " virtual " and should be having the same signature, that is the same return type, same number of parameters and type. The virtual methods does have an implementation which can be overridden in the sub class where as an abstract method must be implemented in the sub class. For e.g. public class A {      public virtual double Area (double r)      {           return r * r;      } } public class B : A {      public override double Area (double r)     {         double p = 3.142;         return base.Area(r) * p;     }...

What is Method Overloading?

Method overloading is a process whereby methods by the same name are declared more than once but with a different signature, it can either be the number of parameters or the type of the parameters. This is provided to overcome the optional parameter options that is there in VB.NET. For e.g. public void methodOverloading (int arg1, int agr2) public void methodOverloading (int arg1, string arg2) public void methodOverloading (int arg1, int agr2, string arg3)

What is the difference between Site Definition and Site Template?

Site Definition Site Definition can be said to be the foundation for building a site in SharePoint, it contains all the artifacts that are needed for the site. A Site Definition can contain multiple site definition configuration. It is a collection of XML (using CAML) and ASPX pages. Each site definition consists of a combination of files that are placed in the %ProgramFiles%\Common Files\Microsoft Shared\web server extensions\14\TEMPLATE\SiteTemplates sub folders of SharePoint Foundation servers during installation of SharePoint Foundation. The XML markup in the site definition files may include references to files in other sub folders of %ProgramFiles%\Common Files\Microsoft Shared\web server extensions\14\TEMPLATE , including .xml, .aspx, .ascx and .master page files, in addition to document template files (.dot, .html) and content files (.gif, .doc). The files related to the Site Definition are stored in the file system of the server and not in the content database. ...

What is the difference between .dwp and .webaprt file in SharePoint?

As such there is no difference between the files based on the usage, they are the same only the version of SharePoint for which it is being used is different. .dwp file is used for version 2 while .webpart is used for version 3. The version of the SharePoint is specified in the xmlns tag In the .webpart file all the properties are provided in separate property tags with a name attribute where as in .dwp file there is a different tag for all the properties.

Steps to create Custom Columns and Custom Content Type using Visual Studio

The steps to be followed to create a custom content type using visual studio are as follows: Open up the VS 2010 with the Admin priviledge Create a new " Content Type Project " Provide the URL of the site where the content type needs to be created and validate it If required deploy it as a SandBox Solution or else deploy it as a Farm Solution and click on the Finish button, this will create the solution Choose the base content type, for e.g. " Item " and click on the Finish button Set the scope of the feature as " Site " or whatever is needed In the Solution Explorer under the name provided for the content type there will be a file as " Elements.xml ", open up the file, it is good to rename the xml file e.g. XXXContentType.xml In this file we need to provide the following details: ID - this is the GUID which is autogenerated Name - the name of the content type Description - the description of the content type Group - the headin...

What is the difference between a Page Layout and Master Page in SharePoint?

A Page Layout is nothing but a template which when used in conjuncture with the Master Page gives the look and feel and contents of the page. Each page layout has an associated content type that determines the kind of content that can be stored on pages based on that page layout. Master Pages and Page Layouts dictate the overall look and feel of your SharePoint site. Master Pages contain controls that are shared across multiple page layouts, such as navigation, search, or language-preference for multilingual sites. Page layouts contain field controls and Web Parts. All page layouts reference a master page that is based on the CustomMasterUrl property of the SPWeb class. The top-level SharePoint Server site for a site collection hosted on SharePoint Server 2010 has a special document library called the Master Page and Page Layout Gallery. All Page Layouts and Master Pages are stored in this document library. Reference: http://blog.beckybertram.com/Lists/Posts/Post...

What is the difference between the SPListItem.Update() and SPListItem.SystemUpdate() methods?

The SPListItem.Update() method is the general use by which the data is a updated to the list along with the changes to the fields Modified, ModifiedBy and to the Version, if it is enabled. But by using the method SPListItem.SystemUpdate(), the changes are reflected to the list but there is no change in the Modified, ModifiedBy field and the Version is also not updated if enabled.

What do you understand by Delegate Control in SharePoint?

By Delegate Control in SharePoint we can add a particular piece of code or control within the master page without affecting the code written there or writing any specific code within the master page, in simple it can be said to be a control containing a child control. At run time, this control accepts the union of control elements declared at the server farm, Web application, site collection, and Web site levels. The control that has the lowest sequence number is added to the control tree by means of the DelegateControl . In the case of a sequence tie, the order of controls is arbitrary. Reference: http://msdn.microsoft.com/en-us/library/ms470880%28v=office.14%29.aspx http://msdn.microsoft.com/en-us/library/ms463169%28v=office.14%29.aspx

What are Sandbox Solutions in SharePoint?

The solutions that are developed for SharePoint can be directly deployed to the farm, but there runs a risk that incase there is any malicious code then the whole farm might be affected. In order to avert any such situation the concept of Sandbox has been developed. Sandbox is a restricted area within the farm, with access to minimal resources, where the users can test their solutions without affecting the running of the farm. The solutions that are being deployed to the sandbox is known as Sandbox Solutions and can only access data from within the site collection where it has been deployed. Since Sandboxed solutions cannot affect the whole server farm, they do not have to be deployed by a farm administrator. Sandboxed solutions can be deployed by a site collection administrator or, in certain situations, by a user who has the Full Control permission level at the root of the site collection. However, only a farm administrator can configure Sandboxed solutions–related settings...

What is the difference between a normal SharePoint list and External List?

An external list is unlike other SharePoint lists. Strictly speaking, it is not a SharePoint list at all because it doesn’t store information inside it. An external list is a view on external data—that is, data that is contained not within SharePoint but in external databases and systems. When you add external lists to SharePoint sites, they are displayed in an interface that looks almost exactly like a regular SharePoint list. An external list also allows most of the same interactions with the items in the list that are offered with a regular SharePoint list.

What is an External Content Type?

External content types are reusable metadata descriptions of connectivity information and data definitions plus the behaviors you want to apply to a certain category of external data. External content types enable you to manage and reuse the metadata and behaviors of a business entity such as Customer or Order from a central location and enable users to interact with that external data and processes in a more meaningful way. The benefits are as follows: Enable Reusability The external content types are reusable data definitions that can be reused using the various methods provided by SharePoint to display the data Encapsulates Complexities of the external system The user need not know the complexities of connecting to the external data source and where it is actually located. Ensure secure access Provides the user with a secure access to the external data source through SharePoint. Simplified Maintenance The maintenance of the external content type can be done from a ce...

What are the limitations of an External List?

The limitations of an external list in SharePoint are as follows: Workflows cannot be configured for an external list Information Management Polices cannot be configured as the data is actually not stored within SharePoint No versioning can be configured hecne no version history is available No rating is possible There is no ability to Export the Data to Excel, Open with Access, Open with Project etc External list items cannot be accessed through REST No RSS Feed No Item level permission can be set No item or field level validation is possible There is no possibility to create lookup columns No attachments can be saved to the list

What are the steps to a deploy a workflow WSP file in SharePoint?

The workflows that are created using the SharePoint Designer are available as a WSP file in the Site Assets document library, the file can be downloaded from here and deployed to another server using the steps mentioned below: Downloading the WSP file Go to the Site Settings of the top level site of the site collection Under the All Contents section select the document library Site Assets There the name of the workflow will be displayed, click on the context menu and select Send To - Download a Copy, select the location where the file needs to be downloaded and save it Uploading the WSP file Go to the Site Settings page of the top level site in the site collection where you need to upload the file Select Galleries - Solution, this will open up the list of the solutions that are already there in the site collection From the ribbon select the command button Upload Document, point to the WSP file already saved and upload the file Once the file has been uploaded, click on the...

jQuery Basics

jQuery Introduction The files needed to run a jQuery function can be downloaded from the URL mentioned below: http://jquery.com/download/ There are actually two versions of the file that is available, the first one id the minified and compressed version, jquery-1.10.1.min.js , which is basically used for the production environment and the other is the full version, uncompressed and readable, which is used for the development environment. If somebody does not want to download the file, they can use it from the CDN (Content Delivery Network) provided both by Google and Microsoft, the details are here under: Google - http://ajax.googleapis.com/ajax/libs/jquery/1.10.1/jquery.min.js Microsoft - http://ajax.aspnetcdn.com/ajax/jQuery/jquery-1.10.1.min.js Note:  If you look at the Google URL above - the version of jQuery is specified in the URL (1.10.1). If you would like to use the latest version of jQuery, you can either remove a number from the end of the version st...

What is the use of the EnsureChildControl method?

The method "EnsureChildControl" is called to check whether the method "CreateChildControls" have yet been called or not, if not it makes sure that it is called.

What is a Web Part in SharePoint?

Image
Web Parts are server side code that runs within the context of the site page in SharePoint. There are many OOTB web parts that are available but one can create their own. There mainly two types of web parts which are as follows: ASP.NET Web Part These Web Parts are built on top of the ASP.NET Web Part infrastructure. The ASP.NET-style Web Parts have a dependency on System.Web.dll and must inherit from the WebPart base class in the System.Web.UI.WebControls.WebParts namespace. You can use these Web Parts in ASP.NET applications and in SharePoint Foundation, which makes them highly reusable. SharePoint Web Part These Web Parts have a dependency on Microsoft.SharePoint.dll and must inherit from the WebPart base class in the Microsoft.SharePoint.WebPartPages namespace. These Web Parts can only be used in SharePoint websites. The custom web parts that are being created can be personalized by declaring properties that are visible to the user in the properties section....

What are the various class files that are being used in SharePoint?

Visual Web Parts Derived: System.Web.UI.UserControl Imports: Microsoft.SharePoint / Microsoft.SharePoint.WebControls Web Parts Derived: System.Web.UI.WebControls.WebParts.WebPart Imports: Microsoft.SharePoint / Microsoft.SharePoint.WebControls Methods: protected override void CreateChildControls() This method is used to create the controls to be displayed public override void RenderControl(HtmlTextWriter writer) This method is used to render the controls within the page Mobile Web Parts Derived: Microsoft.SharePoint.WebPartPages.WebPartMobileAdapter Imports: Microsoft.SharePoint / Microsoft.SharePoint.WebControls / Microsoft.SharePoint.WebPartPages Methods: protected override void CreateControlsForSummaryView() This method is used to create and render the controls within the mobile view page Timer Jobs Derived: Microsoft.SharePoint.Administration.SPJobDefinition Imports: Microsoft.SharePoint / Microsoft.SharePoint.Administration Methods: public...

What are ghosted and unghosted pages?

Ghosted Pages Ghosted pages are those pages whose content does not reside in the content database, they reside on the actual file system disk and a reference to the file is maintained. Hence it can be said that these pages act as a template. From a technical standpoint, ghosted pages are those rows in the docs table which have null values for the Content column and a non-null value for the SetupPath column which points to a file on the file system itself. The referenced file essentially serves as a template and content source. Unghosted Pages When site pages are customized, the page is unghosted and their content is then stored in the content database. These pages are specific to a particular web application. If in the ONET.XML file a page has been marked as an unghosted page then instead of saving the reference to the file the page itself is stored in the content database. The SharePoint SafeMode parser ensures unghosted pages are not allowed to run server side code....

How to create multiple content databases under a web application

By default when we create a Web Application from within the Central Admin a single content database is created which is shared by all the Site Collections under the said Web Application. At times due to the size limitation of 200GB it is desirable to have separate content databases for the site collections. The steps to be followed are as follows: Firstly we need to create the web application in the usual process and create a site collection under it. Now before we create the second site collection we first need to create the second content database under the web application. Under "Application Management - Content Databases" we need to select the web application which will display all the content databases that are already there. We need to click on the link "Add a content database", this will open up a screen where we need to provide the details for the create of a new database. Once the database is created it will be listed under the web application in ...

What is the difference between CustomMasterUrl and MasterUrl?

SharePoint is a content management system targeted towards end users, hence it is supposed to provide maximum functionality out of the box without doing much customizations, let alone changes to the code. So, changing master pages is one of the common requirements by end users, and of course they need it done without changing the code for the page. For end users, they should just select a different master page from a list and it should render for their site. So, to achieve such an architecture SharePoint uses tokens. In SharePoint, master pages are specified in Content Pages (in Non Publishing Sites) and Page Layouts (in Publishing Sites). These pages use tokens to specify a master page in SharePoint. These tokens will be replaced by the actual master page reference. The different types of tokens that are there are as follows: Static Tokens Static tokens will point to the exact location of the master page. Example: If our content page is located at " http://MySi...

What are Application Pages, Site Pages?

Application pages are used to support application implementations in SharePoint Foundation. Application pages are stored on the file system of the front-end Web server in the %ProgramFiles%\Common Files\Microsoft Shared\web server extensions\14\TEMPLATE\LAYOUTS directory and exist for every site in a Web application. This folder is mapped to an IIS virtual directory called " _layouts " . Every site and subsite will have access to the application pages by using the _layouts virtual directory. For example, http://myserver/_layouts/settings.aspx and http://myserver/subsite/_layouts/settings.aspx access the same application page on the front-end Web server unlike site pages, which are an instance for the specified site. Custom Application Pages can be created as can be stored in sub folders within the _layouts folder. No server side coding is allowed on these pages. Site Pages are the page that are created, edited and customized by the users of the site. They ar...

What are the steps to configure the Enterprise Search Center in SharePoint 2010?

The steps to configure the Enterprise Search Center are as follows: Firstly go to Central Admin and create a web application Once the web application has been created, create a site and from the template section choose the template as " Enterprise - Enterprise Search Center " Under the section " My Site Settings " click on the option " Setup My Site " set the " Preferred Search Center ", here you need to provide the URL of the newly created site Reference:  http://sharepointgeorge.com/2010/configuring-enterprise-search-sharepoint-2010/

What are the steps to configure the My Site?

In order to setup and configure the My Site in SharePoint 2010, the steps to be followed are as follows: Logon to the Central Admin with the Admin credentials and create a new Web Application in the desired port Once the web application has been created, create a Site, while creating the site choose the site template as " Enterprise - My Site Host " After site has been created go to " Central Admin - Application Management - Service Applications - Manage Service Applications - User Profile Service Application " In the page that opens up click on the link " My Site Settings - Setup My Site " Under the section " My Site Host " provide the URL of the site that has been created in the steps above Go to " Central Admin - Application Management - Web Applications - Manage Web Application " and select the site created for My Site and make sure that the option " Self-Service Site Collection Management " has been set to " ...

What is a WSP file? Explain the installation process.

Farm solution installation in Microsoft SharePoint is a system that enables developers to package custom farm solutions and administrators to deploy those farm solutions in a straightforward, safe and consistent manner. Specifically, installation refers to the process of uploading and unpacking solution packages (.wsp files) to front-end web servers and deploying the contents. Web Solution Package is a cabinet file that contains assemblies, resource files, features, images, application pages, site definitions etc. into single file. When the solution is being added it is stored in the Farm Solution Store table in the farm's configuration database. When adding a farm solution to the store, the contents of the solution file are validated against an .xsd file to verify that the files contained in it comply with the SharePoint Foundation schemas. If the verification fails, an error message is returned. If the verification succeeds, the process of adding the farm solution cont...

What is the use of the .ddf?

The .ddf (Data Directive File) is the file which contains the details of the files and where it needs to be deployed. It is used when the WSP file is being created, it is sent as a parameter to the MAKECAB.EXE file to generate the WSP file.

What are steps to take IIS backup?

The steps to take a IIS backup in SharePoint are as follows: Start - Administrative Tools - IIS Manager Right click on the Computer Name - All Tasks - Back/Restore Click on the button "Restore" Provide a name and password for the backup created, this will create a backup The backup will be available under the path " C:\WINDOWS\system32\inetsrv\MetaBack ", the extension of the file would ".MDO"

What do you understand by event receivers in SharePoint?

Event Receivers are custom methods that are written to handle certain events within a list or document library. There are basically two types of event receivers, which are as follows: Synchronous Events - these events are like "ItemAdding" or "Uploading" Asynchronous Events - these events are like "ItemAdded" or "Uploaded"  The Event Receivers are either derived from the base class "SPListEventReceiver" or "SPItemEventReceiver".

STSADM command to add/deploy solutions to the server

STSADM is a command line tool provided by SharePoint to deploy, install and uninstall the features with a SharePoint Farm. To run the stsadm command the user needs to be part of the user group "WSS_ADMIN_WPG" and also to the administrator group. The executable file is location in the "bin" folder. Once the solution is ready for deploying in the server, one needs to run the following commands in the server: Adding the Solution : stsadm -o addsolution -filename C:\MHM.MainEmpDirListingCode.wsp Deploying the Solution : stsadm -o deploysolution -name MHM.MainEmpDirListingCode.wsp -url http://172.16.20.150:1975 -allowGacDeployment -immediate Retracting the Solution : stsadm -o retractsolution -name MHM.MainEmpDirListingCode.wsp -allcontenturls -immediate Removing the Solution : stsadm -o deletesolution -name MHM.MainEmpDirListingCode.wsp -override

What is a different between a Site Column and a Content Type?

Content Type is a collection of Site Columns that can be used throughout the site. Where as a site column is a predefined column, for e.g. it can be a single line of text, multiple lines etc.

What are the different types of authentication available in SharePoint?

The different types of authentication available in SharePoint are as follows: Classic Mode Authentication - uses NT authentication types such as Kerberos, NTLM, Basic, Digest and Anonymous Claims Based Authentication - uses claims identity against a trusted provider Windows Authentication - Form Based Authentication -

What is the difference between a list and a document library?

The difference between a list and a document library is as follows: Document Library is used to store documents where lists are used to store data in the form of rows and columns In a document library you can create documents as Word, Excel, PowerPoint, but in a list you cannot create a document but instead one can attach a document to a list item.

Difference between Client Object Model and Server Object Model in SharePoint?

Image
Previously the only way to access data from outside the SharePoint environment was through web services, now there is another way to access the data using the Client Object Model. There are three ways by which one can access the data from the SharePoint environment, which are as follows: .NET Managed Code Assembly In order to access the data the user needs to add a referecne to the following two DLLs from the ISAPI folder: Microsoft.SharePoint.Client Microsoft.SharePoint.Client.Runtime Silverlight Application Assembly In order to access the data the user needs to add a referecne to the following two DLLs from the ClientBin folder: Microsoft.SharePoint.Client.Silverlight Microsoft.SharePoint.Client.Silverlight.Runtime JavaScript For accessing data one needs to add a reference to the SP.js file, which will in turn call the SP.Runtime.js Client Object Model Architecture All the calls that are made from the client object model are in the form of an XML file which is f...

What is the architecture of SharePoint?

SharePoint has a 3 tier architecture which is as follows: Web Server Front End In this layer SharePoint is loaded and configured, the web sites resides in the IIS and we have 14-hive structure. Application Layer SharePoint provides various types of services, these services like the my site hosting, search, user profile and properties are hosted in this layer. Each of these services can be hosted in a separate machine if the need be. Database Layer This is the layer where we have the database resides.

Wnat is CAML?

CAML (Collaborative Application Markup Language) is a custom XML language provided by SharePoint which is used to manipulate the data stored within SharePoint.

What is a SiteCollection in SharePoint?

A Site Collection is a collection of web sites under a web application. Under each site collection there will be a top level site and under that there can be multiple child sites. It is represented as "SPSite" in the object model and each web site under each of the site collection is represented as "SPWeb" in the object model.

What is a WebApplication in SharePoint?

A Web Application is a site in the IIS of the server, the web application can be created from within the Central Administration and has a content database associated with it. It can have multiple sites under it and can be accessed by the different zones within SharePoint. It is represented by the "SPWebApplication" object model.

What is a farm in SharePoint?

A farm is a collection of SharePoint Servers sharing the same configuration database. The configuration database holds all the information needed to run the servers within the farm and is configured and controlled from the Central Administration.

What are zones in SharePoint 2010?

Zones are separate logical paths mapping of the same application, the different zones that are available are as follows: Default Internet Intranet Extranet Custom

What are different types of master pages in SharePoint 2010?

There are basically three types of pages in SharePoint for which we have a corresponding master page, which are as follows: Publishing Pages - these are those pages that are there in the Site Pages document library for e.g. default.aspx --- so we have the Site Master for these kinds of pages. Forms and Views Pages - these are the pages used to view the data stored in the lists and document libraries for e.g. AllItems.aspx --- so we have System Master for these kinds of pages. Application Pages - these are the pages that are stored in the _layouts folder in the server, these are the pages that are used for settings etc. --- so we have Application Master for these kinds of pages. The different types of master pages that are available in SharePoint 2010 are as follows: v4.master - this is the default master page default.master - this is a master page that provides backward compatibility with MOSS 2007 minimal.master -  simple.master - this is used for the accessdenie...

Why do we use properties.current.web instead of SPContext.Current.Web in an event receiver class?

The reason we are using the properties.current.web in the event receiver is because it is not directly accessible over the browser. Since a normal custom application is accessible over the browser we can use the SPContext.Current.Web.

How can we debug a SharePoint Application or a SharePoint Timer Job

The steps to be followed to debug are as follows: Build and deploy the application Set the breakpoint in application Open up the Debug menu and view all the processes that are running For SharePoint Applications attach the process "w3wp.exe" and for SharePoint Timer job attach the process "OWSTIMER.exe" For SharePoint Application just refresh the application and for the timer jobs just run the job from the list

Explain workflows in SharePoint

Image
A workflow allows you to attach a business process to items in Microsoft SharePoint Foundation 2010. This process can control almost any aspect of an item in SharePoint Foundation 2010, including the life cycle of that item. For example, you could create a simple workflow that routes a document to a series of users for approval. Workflows can be as simple or complex as your business processes require. You can create workflows that the user initiates, or workflows that SharePoint Foundation 2010 automatically initiate based on some event, such as when an item is created or changed. SharePoint Foundation 2010 workflows are made available to end-users at the list or document-library level. Workflows can be added to documents or list items. Workflow can also be added to content types. Multiple workflows may be available for a given item. Multiple workflows can run simultaneously on the same item, but only one instance of a specific workflow can run on a specific item at any given time...