Posts

Showing posts from June, 2013

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...